Image

Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Sandbox

Testing ground for new challenges. Post here to get feedback, edit to adjust, and then when you're ready, post in Challenges.

Filters (None)
50%
+0 −0
Shortest knight's sightseeing tour

Find a closed knight's sightseeing tour[1] of a 61 by 61 board. Shortest wins. Definitions A square is visible from another square if it is a knight's move away from it. A closed knight's sigh...

posted 2mo ago by trichoplax‭  ·  edited 27d ago by trichoplax‭

50%
+0 −0
5 by 5 knight's tour string validator [FINALIZED]

Now posted: 5 by 5 knight's tour string validator The squares of a 5 by 5 chessboard are labelled with the letters A to Y in English reading order: A B C D E F G H I J K L M N O P Q R S T U...

posted 2mo ago by trichoplax‭  ·  edited 2mo ago by trichoplax‭

50%
+0 −0
A knight's tour

Generate a sequence of squares on a chessboard that are a knight's move apart and cover all of the squares. Input A number $N$ from 5 to 26 inclusive. Output A sequence of squares, in any...

posted 3mo ago by trichoplax‭  ·  edited 2mo ago by trichoplax‭

50%
+0 −0
Number of sides on a polygon [FINALIZED]

Now posted: Number of sides on a polygon Input The name of a polygon. You are only required to handle inputs listed in the test cases. Output The number of edges the polygon has. Te...

posted 3mo ago by trichoplax‭  ·  edited 3mo ago by trichoplax‭

60%
+1 −0
Digits from words [FINALIZED]

Now posted: Digits from words Convert a number in words to digits. Input A number in words from one to ninety-nine. Output The corresponding number in digits from 1 to 99. This may be...

posted 3mo ago by trichoplax‭  ·  edited 3mo ago by trichoplax‭

50%
+0 −0
Cod golf: condense your shoal [FINALIZED]

Now posted: Cod golf: condense your shoal Your answer is a string containing 255 fishes as subsequences, and your score is the length of that string in bytes (lowest score wins). Rules Your ...

posted 3y ago by trichoplax‭  ·  edited 3mo ago by trichoplax‭

60%
+1 −0
Single letter HTML [FINALIZED]

Now posted: Single letter HTML Indicate whether a letter is an HTML element. Input A single lowercase letter. Output An indication of whether the input is a standard HTML element. Thi...

posted 4mo ago by trichoplax‭  ·  edited 3mo ago by trichoplax‭

50%
+0 −0
Connected ​bits [FINALIZED]

Now posted: Connected ​bits Indicate whether the 1s and 0s in an 8 by 8 grid are connected. The grid Connectedness is by orthogonal adjacency (up, down, left, right). Diagonal adjacency doe...

posted 4mo ago by trichoplax‭  ·  edited 4mo ago by trichoplax‭

60%
+1 −0
Lone ​​​​​​ones [FINALIZED]

Now posted: Lone ​​​​​​ones Given an integer, output the number of lone 1s in its binary representation. Input An integer from $0$ to $4294967295$ (that is, $2^{32}-1$). In binary that's fro...

posted 4mo ago by trichoplax‭  ·  edited 4mo ago by trichoplax‭

33%
+0 −2
💥 CHALLENGE: Find a Collision in Leviathan v3.1 (Deterministic)

The Context: I have officially deprecated SHA-2 and SHA-3. This decision stems from a critical security breach I witnessed: a virus that infected my system using forged digital signatures that wer...

posted 5mo ago by KaoruAK‭  ·  edited 5mo ago by KaoruAK‭

50%
+0 −0
Digits with subsets of unique population size

Output a sequence of digits, with no 2 subsets of the digits 0 to 9 having equal population size. Input There is no input for this challenge. Output A finite sequence of digits from 012345678...

posted 2y ago by trichoplax‭  ·  edited 7mo ago by trichoplax‭

50%
+0 −0
Awkward Ordinals [FINALIZED]

Now posted: Awkward Ordinals Write code that takes a positive integer and outputs the awkward ordinal name from the test cases. Notice that these are not the conventional ordinal names, although...

posted 1y ago by trichoplax‭  ·  edited 1y ago by trichoplax‭

60%
+1 −0
Digit balanced numbers [FINALIZED]

Now posted: Digit balanced numbers Does a number have balanced numbers of distinct digits? That is, do the number's digits appear with equal frequency? Input A positive integer N. N will ha...

posted 1y ago by trichoplax‭  ·  edited 1y ago by trichoplax‭

50%
+0 −0
Expand a greyscale/colour hex code [FINALIZED]

Now posted: Expand a greyscale/colour hex code Consider a type of hexadecimal colour code that supports shorthand for both greyscale and colour: A 6 digit code is interpreted as 2 digits for ...

posted 1y ago by trichoplax‭  ·  edited 1y ago by trichoplax‭

71%
+3 −0
Display a Progress Bar [FINALIZED]

Now finalized: Display a Progress Bar The goal of this challenge is simple: given a ratio of whole numbers, output a 50-character long progress bar representing the ratio. Rules Input Your pr...

posted 1y ago by Sylvester‭  ·  edited 1y ago by trichoplax‭

71%
+3 −0
Source with the whole alphabet in order of appearance [FINALIZED]

The challenge is to write as short a source as possible, where the English alphabet (in alphabetical order from top to bottom) "abcdefghijklmnopqrstuvwxyz" is a subsequence of the source code. The...

posted 2y ago by Lundin‭  ·  edited 1y ago by trichoplax‭

60%
+1 −0
Product of polynomials modulo 2 in integer representation

Your task is to implements the product of polynomials modulo 2 $(\mathbb F_2[x]$) in integer representation. Background The field $\mathbb F_2$ represents the integers modulo 2, or equivalently, ...

posted 1y ago by celtschk‭  ·  edited 1y ago by celtschk‭

50%
+0 −0
3D compass point from 3D coordinates

Given 3 dimensional (3D) Cartesian coordinates (x, y, z), output the 3D compass point that comes nearest to describing the direction from the origin. Definitions Directions In reality, the direc...

posted 3y ago by trichoplax‭  ·  edited 1y ago by trichoplax‭

60%
+1 −0
Plain ​​spheres

Given a list of spheres, output an image. Produce a greyscale orthographic (parallel projection - no perspective) ray caster, that renders only plain grey spheres with no lighting. Input A lis...

posted 2y ago by trichoplax‭  ·  edited 1y ago by trichoplax‭

50%
+0 −0
Multiplicative perfection [FINALIZED]

Now posts: Multiplicative perfection Given a positive integer, indicate whether it is the product of its proper divisors. Integers equal to the product of their proper divisors can be found on ...

posted 1y ago by trichoplax‭  ·  edited 1y ago by trichoplax‭

50%
+0 −0
How many odd digits? [FINALIZED]

Now posted: How many odd digits? Given a positive integer, count its odd digits. Input An integer from 1 to 999,999,999, inclusive. Output The number of odd digits in the input. Tes...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

66%
+2 −0
Net​​ or​​ not? [FINALIZED]

Now posted: Net​​ or​​ not? Given a hexomino, indicate whether it is a net of a cube. Input A 6 by 6 grid containing exactly 6 filled squares. The 6 filled squares will be in a single edge ...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

50%
+0 −0
Substring factor [FINALIZED]

Now posted: Substring factor Does a positive integer have a substring as a factor? Input A positive integer. Output One of 2 distinct values to indicate whether the input has a factor ...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

60%
+1 −0
Most isolated of 3 points [FINALIZED]

Now posted: Most isolated of 3 points Given 3 points, output one that is separated from its nearest neighbour by the largest distance. Input 3 distinct points (that is, no 2 points are in th...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

50%
+0 −0
Hex ​​​detector [FINALIZED]

Now posted: Hex ​​​detector Given an integer from 1 to 1000, indicate whether it is a centered hexagonal number (also known as a hex number). What is a hex number? The hex numbers can be visua...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

66%
+2 −0
Fibonascii Squares [FINALIZED]

Finalized: Fibonascii Squares The Challenge Your job is to, given input positive non-zero integer $n$, output an ASCII representation of the tiled Fibonacci squares up to the $n$th number of th...

posted 2y ago by Sylvester‭  ·  edited 2y ago by trichoplax‭

50%
+0 −0
Round trip stones [FINALIZED]

Now posted: Round trip stones $N$ vessels initially contain $3$ stones each. What is the probability of having at least $3$ stones in the first vessel after moving a uniformly random selection f...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

66%
+2 −0
The 50 substrings that validate any string of Roman numerals [FINALIZED]

Now posted: The 50 substrings that validate any string of Roman numerals Given a string of Roman numerals, decide whether it forms a valid Roman number. If not, output the substring that proves ...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

71%
+3 −0
12-hour time is weird [finalized]

Posted: https://codegolf.codidact.com/posts/291018 Your mission for today, should you choose to accept it, is to write a simple 12-hour clock calculator. Your input will always be in the form of a...

posted 2y ago by honnza‭  ·  edited 2y ago by honnza‭

50%
+0 −0
Fibonacci numbers with no consecutive digits [FINALIZED]

Now posted: Fibonacci without consecutive digits Output the Nth number in the list of Fibonacci numbers that have no consecutive digits. Input A non-negative integer. Output The Nth nu...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

50%
+0 −0
Print virtual fractions / 2-adic fractions / Modular multiplicative inverse [FINALIZED]

Now posted: Print virtual fractions / 2-adic fractions / Modular multiplicative inverse TL;DR Print this values (or an extension of them): 1 43691 52429 28087 36409 35747 20165 61167 6...

posted 2y ago by H_H‭  ·  edited 2y ago by trichoplax‭

60%
+1 −0
Arbitrary angle wrapping wordsearch

Sandbox Would you change anything about the test case format? Are there any more edge cases to add to the test cases? Should words that use the same grid position more than once be c...

posted 3y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

50%
+0 −0
Shortest representation in generalised Roman numerals [FINALIZED]

Posted Given an integer, find its shortest representation in generalised Roman numerals. Since there is more than one way to generalise, only the definition shown below applies to this challenge. ...

posted 3y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

50%
+0 −0
Single character Roman numeral [FINALIZED]

Now posted: Single digit Roman numeral Given a single character, which is a valid Roman numeral, output its value. Values There are 7 valid single character Roman numerals, with the following va...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

60%
+1 −0
Borromean coprimes [FINALIZED]

Now posted: Borromean coprimes Given 3 positive integers, indicate whether they are Borromean coprimes. Definition 3 positive integers are called Borromean coprimes if both of the following ar...

posted 2y ago by trichoplax‭  ·  edited 2y ago by trichoplax‭

60%
+1 −0
Is it part of the mandelbrot set? [FINALIZED]

Now posted Input is a number, you have to decide if it is part of the mandelbrot set or not, after at least 16 iterations. This is done by applying this formula: $z_n = z_{n-1}^2 + c$ repeatedl...

posted 3y ago by H_H‭  ·  edited 3y ago by trichoplax‭

50%
+0 −0
A word suggester [FINALIZED]

Now posted: Word suggesting Suggest a word from a word list, given a string. Motivation Imagine typing a word one letter at a time, and seeing a suggested word after each letter is typed. At f...

posted 3y ago by trichoplax‭  ·  edited 3y ago by trichoplax‭

60%
+1 −0
Probability of rolling all 6 dice faces [FINALIZED]

Now posted: Probability of rolling all 6 dice faces The probability of rolling every number from 1 to 6 with $N$ six-sided dice. Input A positive integer $N$. Your code must work for inputs...

posted 3y ago by trichoplax‭  ·  edited 3y ago by trichoplax‭

66%
+2 −0
Expected value of highest dice rolled [FINALIZED]

Now posted: Expected value of highest dice rolled You roll $N$ dice simultaneously. Your score is the highest number rolled. If you play this game many times, what is the expected value (mean) o...

posted 3y ago by trichoplax‭  ·  edited 3y ago by trichoplax‭

66%
+2 −0
Caesar shift cipher [released]

Introduction What is ROT13? It's basically a cipher sequence that changes a letter's value from the number chosen. If we use ROT1 on "games", we get "hbnft". The basic interpretation of ROT13 is i...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

50%
+0 −0
99 Shortened Bottles of Beer [released]

Disclaimer This challenge also exists in CGCC, but if you want to compete here (too), then hop in! Challenge Recreate "99 Bottles of Beer on the Wall", using the least bytes possible. Lyrics: ...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

66%
+2 −0
A chunk of symbols is a calculation [released]

Challenge Create a program that takes input of a string and outputs an integer using the following calculation system: The string can only contain +, -, *, /, ^, ! (or a different character; ! ...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

60%
+1 −0
My house is destroyed! Can you make me one? [released]

Background I went on an adventure Grabbed resources and making deeds Like start to work on the materials To build the shelter I need It was a marvelous one At least in the eyes of mine And w...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

60%
+1 −0
Make my value binary [released]

Challenge What do computers understand? That's right, binary. All files are turned into binary digits when you run them, but what if I suggest giving you an int then turn it into it's binary value...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

66%
+2 −0
Stairs? Stairs! Stairs. [released]

Challenge Make a program that takes input of an integer that's $n > 1$ and print out a staircase using a specific character for stair basing (hashes (#) for demonstration; you can use spaces,...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

60%
+1 −0
Abbreviate everything [released]

Challenge Make a program that takes input of a string and abbreviate it. All letters of an abbreviation are capitalized, so keep that in mind. Whitespace, numbers and non-English characters ar...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

60%
+1 −0
Reverse your quine [released]

Challenge Write a program that prints its reversed self. For example, if your code is foo() Then it'll output: )(oof Make sure that the quine is a valid one, as defined here: No cheatin...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

75%
+4 −0
Collatz conjecture; Count the tries to reach $1$ [released]

Background Check out this video on the Collatz conjecture, also known as A006577[1]. If you don't know what this is, we're given an equation of $3x + 1$, and it is applied this way: If $x$ is ...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

60%
+1 −0
Define a mathematical expression in English [released]

Background Inspired by this challenge that is also a mathematical English translator. Challenge Write a program that translates a mathematical expression using English with the following specifi...

posted 5y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭

71%
+3 −0
Operation "Find The Operator" [released]

Challenge Make a program that takes input of 3 non-negative integers: a result and 2 other values that once calculated results to the 3rd value. The program must figure out how to get the 2 fir...

posted 4y ago by General Sebast1an‭  ·  edited 3y ago by trichoplax‭