text
stringlengths
180
608k
[Question] [ # Prelude: I wanted to train making test cases, so I'm gonna try them on something easy. # Challenge: Take any given (string) input (within visible ASCII range) and deduce if it's a number and output something that could be used to evaluate. # Rules: * A number will only contain the characters `-012345...
[Question] [ # Definition Here is the process to describe a number: * For each number from `0` to `9` that is present in the number: * Write down the frequency of that digit and then the digit. For example, for the number `10213223`: * There is `1` occurrence of `0`, * `2` occurrences of `1`, * `3` occurrences of `...
[Question] [ Given a Gaussian integer \$a+bi\$ where \$a\$,\$b\$ are integers and \$i = \exp\left(\pi i/2\right)\$ is the imaginary unit, return the closest (w.r.t to the Euclidean distance) Eisenstein integer \$k+l\omega\$ where \$k\$,\$l\$ are integers and \$\omega = \exp(2\pi i/3) = (-1+i\sqrt{3})/2\$. ### Backg...
[Question] [ Given an `m` by `n` chocolate bar, `m,n` positive, output the number of ways to break the bar into `mn` 1 by 1 pieces where each break occurs on a gridline. Order is important. Pieces are also distinguishable, so the two pieces on either end of a 1 by 3 chocolate bar are not equivalent. For instance, f...
[Question] [ ``` +--+ +--+ | | +--+ +--+ | | | | | | | | +--+ +--+ +--+ +--+ ``` The people of ASCIIville are rebuilding their city and are sketching out new blueprints. Your job is to draw their new city based on how many buildings they want. The input will be how many buildings there are. Each building ...
[Question] [ Write the shortest program possible that takes in a set of distinct positive integers and outputs an ASCII rendering of [concentric](http://en.wikipedia.org/wiki/Concentric) hexagons with those side lengths, made from slashes, underscores, spaces, and newlines. The shortest program in bytes as counted ...
[Question] [ [Curling](https://en.wikipedia.org/wiki/Curling) is a sport where two teams aim to place stones as close to the centre of a target as possible. The winner of a curling end is the team whose stone is closest to the centre – they score as many points as the number of their stones closer to the centre tha...
[Question] [ Magic the gathering has many unique names for colour combinations in decks, as an example when Blue and White appear together in a deck, the deck maye sometimes be named after the Ravnican Guild that features those colours, namely 'Azorius'. There are some exceptions, and oddities though. Below is a li...
[Question] [ # Challenge I've recently gotten into 8-bit computers and are fascinated with the workings of them and others alike; thus the objective of this code golf, is to replicate a portion of the Woz Monitor, designed by Steve Wozniak for the Apple I. You are to store an array of 22 hexadecimal values with a ...
[Question] [ ## Background [Actually](https://github.com/Mego/Seriously) (the successor to [Seriously](https://github.com/Mego/Seriously/tree/v1)) is a stack-based imperative golfing language I created in November of 2015. Like many other golfing languages, it has one-byte commands that perform different functions ...
[Question] [ There are *popular* check digit algorithms such as Luhn and then there are *good* ones, for example the Damm algorithm. The only possible reason behind the popularity of algorithms such as Luhn is that there exist code golfed implementations of them. This means that we as a community have the power to ...
[Question] [ A curious kid uses a program which can factorize a number or an expression into the following form: `p1^e1 * p2^e2 * ... * pn^en` . Exponents equal to `1` are omitted e.g. `360 = 2^3 * 3^2 * 5` The kid types this output into the program as new input but they don't understand the `^` sign so sometimes t...
[Question] [ A lazy physicist has the job to perform the double slit experiment. However, they are lazy and can't be bothered to set up all the equipment themselves and so are going to simulate the effects. They can't program though so are going to need some help. As they are lazy your program should be as short as...
[Question] [ Write a program that keeps track of the number of consecutive days it has been run. The day resets at midnight (the local time of the computer on which the program is run). If there is a day that the program is not run, the counter is reset to zero. Every time the program is run, the counter should ...
[Question] [ ## Introduction Long story short: a few days ago I accidentally started knitting a sock and the pretty logical structure of the plain stitches lead me to the idea: Why don't we just ASCII-knit a sock? ## Input The input is an even integer N in the range `[2,30]`. ## Output The output is a sock, obvious...
[Question] [ Don't you find that reading simple text isn't appealing enough? Try our ``` ##### ### ### ##### ##### ##### ##### # # ##### # # # # # # # # # # # # # # ##### ### # # # # #### # # # # # # # # # # ...
[Question] [ Your challenge is to format a list of words across multiple lines that are no longer than a given number of characters, so that each line contains as many words as possible and no words are unnecessarily cut off. ## Input The input will be a space-separated list of words and then a number that is at le...
[Question] [ In this code golf, you will have to determine the direction of the shortest shot that hits exactly **n** cushions before falling into a pocket. The billiard table is a 6 pocket pool table with the following characteristics: * Dimensions are variable (**a** x **b**) * No friction : the ball will roll fo...
[Question] [ ### Background One-hundred and thirteen years ago, amateur cryptographer Félix Delastelle published his work on the [four-square cipher](https://en.wikipedia.org/wiki/Four-square_cipher), a digraphic substitution cipher that accepts two permutations of a 25-letter alphabet as keys and encodes messages ...
[Question] [ ### Background MIDI files are quite different from WAV or MP3 audio files. MP3 and WAV files contain bytes representing a "recording" of the audio, while MIDI files have a series of MIDI messages stored in MIDI events informing a MIDI synthesizer which virtual instrument to play or a MIDI sequencer the...
[Question] [ Load an image into this stack snippet and move your mouse over it. A black curve that follows the [hue](http://en.wikipedia.org/wiki/Hue) angle, starting at your cursor point, will be drawn: ``` <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script><style>canvas{border...
[Question] [ Prior to the discovery of fingerprints and DNA testing, the British police used an anthropometric system to identify repeat offenders. Certain parts of the bodies of criminals were measured and stored in records -- these parts of the body were assumed to not change in size after adulthood. This system ...
[Question] [ As you may know, hackers are everywhere and they want to hack everything. You were asked to make [password requirements which will stop any hacker](http://thedailywtf.com/Articles/Security-by-PostIt.aspx). The problem is, that your boss has heard that paying for LOC is evil and he pays you $1800 - $0.0...
[Question] [ [Carcassonne](https://en.wikipedia.org/wiki/Carcassonne_(board_game)) is a tile-based game, where the objective is to construct Roads, Cities and Monasteries, in order to score points. The game works by players taking turns to draw and place tiles to construct a landscape, then claiming roads, cities a...
[Question] [ ## Goal Write a function or a program that when given a string, for example `"The quick brown fox jumps over the lazy dog"`, outputs: ``` T h e q u i e r t h e c v k o l a b s z r p y o m g o ...
[Question] [ ## Intro Help! I'm stuck on a snow-covered mountain and I need to get down as fast as possible, preferably without dying. I have a map showing how high each part of the mountain is above the normal ground. I am a novice skier, which means I like to stick to slopes that aren't too steep. I'm willing to ...
[Question] [ I have a [combinatorics problem](https://math.stackexchange.com/q/2465571/121988) that I'd like to put on the [OEIS](https://oeis.org/)—the problem is that I don't have enough terms. This code challenge is to help me compute more terms, and the winner will be the user with the submission containing the...
[Question] [ ## Background I saw this very interesting Venn Diagram on wikipedia: <https://simple.wikipedia.org/wiki/Alphabet#/media/File:Venn_diagram_gr_la_ru.svg> It shows the letters (physical shapes) in different alphabets that are common between Russian, Greek and Latin alphabets. ## The Challenge Given an inp...
[Question] [ Last time you made [a square of text](https://codegolf.stackexchange.com/questions/88926/a-square-of-text), but now, can you make a **cube** of text? ## The Challenge Given a string, output the string in the form of a cube. You can assume the string will always have 2 chars or more, and will only have ...
[Question] [ The internet has failed. DDoS attacks are now rampant and widespread. It is up to you to take control and repair the internet. Each bot will control 20 nodes in this network. Every node is either *active* or *safe*, has an owner, and has a strength, which starts at 2. Every active node is connected to ...
[Question] [ On December 4, 2017, the Google Doodle was a [graphical programming game featuring a bunny](https://www.google.com/doodles/celebrating-50-years-of-kids-coding). The later levels were nicely non-trivial and they seemed like a great candidate for an [atomic-golf](/questions/tagged/atomic-golf "show quest...
[Question] [ ## Introduction: I'm a twisty puzzles collector. [Here you can see my current collection of ± 300 puzzles.](http://twistypuzzles.com/forum/viewtopic.php?f=14&t=26889) I think everyone knows the regular Rubik's Cube (3x3x3 Cube), which is a *NxNxN* Cube. There are also Cuboids (block-shaped puzzles), wh...
[Question] [ Palindromes are fun, but some of the other strings are starting to feel left out. We can turn those strings into *chunky palindromes* by splitting them up into palindromic arrays of chunks. For example, the string `"abcabca"` isn't a palindrome if we read it character by character, but we have three di...
[Question] [ *This challenge is loosely inspired by the unimplemented esolang [Pada](https://esolangs.org/wiki/Pada).* Consider an array of 8 bits, all initialised to zero. We'll introduce a very minimalistic instruction set to print arbitrary strings. There are two instructions, both of which take a parameter `N` ...
[Question] [ Write a program or function that takes in a positive integer and prints or returns an ASCII art depiction of an [archery arrow](https://en.wikipedia.org/wiki/Arrow), scaled according to the input. If the input is `1` the output is ``` /\ / \ \__/ || || || || || || || || /||\ / || ...
[Question] [ Write a program or function (or set of programs/functions) to encrypt and decrypt data given the following specification: ## Encryption 1. Calculate an XOR hash of the input by XOR-ing every byte with each-other. 2. XOR every byte of the input by this hash. 3. Shift the result four bits left. 4. Pad th...
[Question] [ > > **EDIT : Recently, my question has been proposed as a duplicate of [2048 Bot Challenge](https://codegolf.stackexchange.com/questions/25226/2048-bot-challenge). I would like to stress that this question is different from that question, and will require answers to be thought of differently than that...
[Question] [ ## Background [Lambda calculus](https://en.wikipedia.org/wiki/Lambda_calculus) is a model of computation using *lambda terms*. * A variable \$x\$ is a lambda term. * If \$E\$ is a lambda term, the lambda abstraction \$\lambda x. E\$ is a lambda term. * If \$E\_1, E\_2\$ are lambda terms, the lambda app...
[Question] [ Stackylogic is a programming language I made up in a previous challenge: **[Run Stackylogic](https://codegolf.stackexchange.com/questions/84851/run-stackylogic)**. Read that post for full details and examples, but here is how it works paraphrased: > > Stackylogic takes `0`'s and `1`'s for input and ou...
[Question] [ # The Challenge Given a `n x m` matrix with `n > 1` and `m > 1` filled with integers ``` 1 2 3 4 5 6 ``` and a list of integers with exactly as many values as `2x2` blocks in the matrix (`(n-1)*(m-1)` if you need the exact number) ``` [1, 2] ``` Output the matrix with every `2x2` block rotated by the c...
[Question] [ Note: this challenge involves downloading and sifting through HTML webpages. If your language cannot handle this you might not want to participate in this challenge. # Introduction There are always discussions over in [The Nineteenth Byte Chat](http://chat.stackexchange.com/rooms/240/the-nineteenth-byt...
[Question] [ **Introduction** A family of seals are stranded upon an iceberg in the Arctic Circle. There is a radio transmitter located on the iceberg which the seals can use to call for help. However, only the daddy seal knows how to operate the radio transmitter. And worse, the ice is very slippery this time of y...
[Question] [ Well the [community](https://codegolf.stackexchange.com/users/-1/community?tab=activity&sort=revisions) is just a bot. But what if it would have been a person? Your task is to find what community's reputation might have been if it would have been given reputation for the edits it makes.(simply 2\*edits...
[Question] [ Inspired by [this question from electronics.SE](https://electronics.stackexchange.com/questions/77227/is-simple-voice-synthesis-just-digits-0-9-possible-with-cortex-m0-with-4kb-fl), here's a challenge for you: **Write a program or subroutine that takes in a sequence of decimal digits (0 to 9) and speak...
[Question] [ Not to be confused with [Password Bishop Goodness](https://codegolf.stackexchange.com/questions/179841/password-bishop-goodness)! Given a string, answer (truthy/falsy or two consistent values) if it constitutes a password which is *strong against bishops*. A password is *strong against bishops* if it i...
[Question] [ A knight fill is a flood fill using the connectivity of the knight chess piece. Specifically: ``` 1 1 1 1 0 1 1 1 1 ``` (0 is the initial point, 1s show the connected cells) ## Challenge Given a 2D grid of spaces and walls, and an initial location, perform a knight-fill on the grid. Shortest co...
[Question] [ I was watching the world snooker championship and it got me wondering.. **Snooker scoring** In the game of snooker there are certain rules that you must adhere too: * When there are red balls on the table, during your turn you must first pot a red ball * After potting each red ball, you must pot a colo...
[Question] [ ## Introduction [Dobble/SpotIt](https://boardgamegeek.com/boardgame/63268/spot-it) is a card game, where people have to spot same symbol on pair of cards in shortest time, indicate it and move to next pair. Each card has multiple symbols (8 in normal version), but exactly one is common between each pa...
[Question] [ In an effort to level the playing field between languages with built-in date libraries and those without, let's work with a fictional calendar. The Forgotten Realms are a (*the?*) campaign setting for Dungeons & Dragons. Of course, each have their own calendar. ## The Calendar of Harptos Conveniently,...
[Question] [ A man has two devices. * **A time machine** - He can control this machine by thinking. It allows him to travel from any point in time to another point in time in the past or future (or even the present point in time) in no time at all. Note that if he travels to the past from B to A, then all normal ev...
[Question] [ Given a square of text representing a spiral of characters, rotate it! The spiral starts at the center and moves *counterclockwise* to the outer edge, starting to the left of center: ``` 987 216 345 ``` This translates to the string `123456789`. Rotation is done *to the left*, so if you rotate it one p...
[Question] [ Given a dictionary file (a text file containing a word or phrase on each line, with possible punctuation but no numbers; lines are alphabetized), you must output each combination of words where one letter can be removed from a word to make another; the removed letter should be encased in parentheses. F...
[Question] [ I like to golf in `dc`, but I'm sometimes frustrated because `dc` doesn't have bitwise operations. # Challenge Provide four named functions which implement the equivalent of the c bitwise operations `&`, `|`, `~` and `^` (bitwise AND, OR, NOT and XOR). Each function will take two operands (`~` takes on...
[Question] [ # Food shortage in the Snakepit For the first time in 35 years, the snakepit is running out of food. The inhabitant snakes now have to fight each other in order to survive this food shortage. Only one snake can stand at the top of the food chain! --- ## Leaderboard *Not here yet!* *Last update on Febru...
[Question] [ Given a string where the first line contains spaces and one period (`.`, the "ball"), followed by lines containing spaces, forward slashes (`/`), and backslashes (`\`), determine what column the ball will land in after falling from its starting position. Each `/` moves it to the left by 1 column and ea...
[Question] [ `xxd` is a utility, bundled with `vim`, that has been used to encode answers to code golf problems on this site. It converts a binary file into a hex dump and back again. Implement the `xxd` and `xxd -r` commands in the programming language(s) of your choice. Scoring is based on the character/byte leng...
[Question] [ I think everyone is familiar with the game of [snakes & ladders](https://en.wikipedia.org/wiki/Snakes_and_Ladders)1. Imagine we have a 10x10 board like this: ``` ============================================================= | | | | | | | | | | | | 100 | 99 | 98 ...
[Question] [ You are given an [countable ordinal](https://en.wikipedia.org/wiki/Ordinal_number) \$1 < r < \varepsilon\_0\$. Determine whether or not it is [prime](https://en.wikipedia.org/wiki/Ordinal_arithmetic#Factorization_into_primes). If not, provide exactly two ordinals \$r\_0, r\_1 < r\$ such that \$r\_0r\_1...
[Question] [ Many programming language provide operators for manipulating the binary (base-2) digits of integers. Here is one way to generalize these operators to other bases: Let *x* and *y* be single-digit numbers in base *B*. Define the unary operator `~` and binary operators `&`, `|`, and `^` such that: * ~x = ...
[Question] [ This was inspired by a [now removed CS.SE question](https://cs.stackexchange.com/q/63892/23039). ### Task Given two non-empty input strings A and B, output the smallest distance from A to a palindrome that contains B as a substring. Distance is defined by the number of character replacements ([Hamming ...
[Question] [ You are given a set of logic statements. Your challenge is to remove any ones that contradict the others, but in the optimal way (i.e. removing a minimal number of statements). ### Challenge You will write a program or a function that takes as input a list of statements, removes **the minimal number** ...
[Question] [ # Fast Trigonometry Calculations Your task is to create a program which can calculate the sine, cosine and tangent of an angle in degrees. ## Rules * No built-in trigonometry functions (not even secant, cosecant and cotangent if your language has them). * You may use lookup tables, but their total size...
[Question] [ [Beal's Conjecture](http://en.wikipedia.org/wiki/Beal%27s_conjecture) has a million dollar prize if you prove/disprove it. It states that if ![A^x + B^y = C^z](https://i.stack.imgur.com/XGNLC.png) where A, B, C, x, y, and z are positive integers with x, y, z > 2, then A, B, and C have a common prime fa...
[Question] [ Your task is to generate a nonsense word that is reasonably pronounceable with the specified number of 'syllables'. Each time the program is run possibly results in a different nonsense word. # Pronounceability A pronounceable word is made up of syllables, which are in turn made up of a vowel group tha...
[Question] [ ### Introduction Let a field be a rectangle filled with *only* the characters `-` and `[0-9]`. An example of a field is: ``` 11-011123 111-010-- 0010---01 111-01234 ``` You see that this field has been separated into three smaller areas: [![enter image description here](https://i.stack.imgur.com/uFprW....
[Question] [ After you wake in a dark room, you see a rectangular grid of lights with corresponding switches. You decide to use a coordinate system with the bottom left light representing (1,1) and the coordinates increasing as you go up (y direction) and to the right (x direction). The grids are identical in that ...
[Question] [ In this challence, your task is to locate substrings with a given structure. # Input Your input shall be two non-empty alphanumeric strings, a *pattern* `p` and a *text* `t`. The idea is that each character of `p` represents a contiguous non-empty substring of `t` which occur next to each other, and `p...
[Question] [ Given a string representing the current state of a game of [Monopoly](http://en.wikipedia.org/wiki/Monopoly_%28game%29) at the beginning of a player's turn, compress all the necessary data into the smallest output. Answers will be judged by **output size** and **source size**. Note: There are many regi...
[Question] [ **WARNING: this is a fairly complex problem, in a king-of-the-hill combat style, with an added randomness to it, the best code may not always win. Please read all rules in full, as it is quite complex!** # Flavor text Bill and Steve decided to have a "friendly" duel, however being so rich and smart, de...
[Question] [ In this challenge you will be asked to take a [knot](https://en.wikipedia.org/wiki/Knot_theory) and determine if it can be colored in a particular way. First we draw a diagram of the knot. We use the standard way of drawing knots where we put gaps in strands where they pass under each other. Here is an...
[Question] [ Sorting makes no sense for a 2-dimensional array... or does it? Your task is to take an input grid and apply a bubble-sort-like algorithm to it until all values in the grid are non-decreasing from left to right and top to bottom along every row and column. The algorithm works as follows: * Each pass go...
[Question] [ *(no, not [those ones](https://oeis.org/A000217))* ## The Challenge You'll be given two inputs. The first is a positive integer `n > 0`, which is used to output an `n x n` right triangle of the numbers `1, 2, 3, ... n`. This triangle starts in a corner and increases horizontally and vertically by one a...
[Question] [ (Inspired while drawing on a dry erase board) ### Challenge: Given an input string containing characters that represent different colors of dry erase markers on a white board, output the order in which they were drawn, from first to last. ### Input: A string which contains dry erase marker colors which...
[Question] [ Leonardo da Pisano *a.k.a* Fibonacci was instrumental in bringing the Hindu-Arabic numeral system into Europe. Before that, mathematicians there worked in base sixty with Roman numerals. For example, the square root of two might be approximated as: *one and twenty-four parts of sixty and fifty-one part...
[Question] [ I like ascii art and I get bored a lot, so I found some ascii characters and started to make random things, 8-bit mario castle, mazes, and arches. I found that the arches could easily be stacked in a neat way. ``` ‚ïî‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïó ‚ïë‚ïî‚ïê‚ïê‚ïê‚ïê‚ïê‚ïó‚ïë ‚ïë‚ïë‚ïî‚ïê‚ïê‚ïê‚ïó‚ïë‚ïë ‚ïë‚ï...
[Question] [ Your task in this challenge is to analyize a given "Matchstick Equation" like this one... ![enter image description here](https://i.stack.imgur.com/PEHMb.png) ... and to find out whether it can be turned into a valid equation by rearranging the matches. If so, you are to output the least number of move...
[Question] [ ### Background [Piet](https://github.com/gleitz/npiet) is an esoteric stack-based programming language in which programs are images meant to resemble abstract paintings. To keep the challenge from being unnecessarily complex, you will not have to consider most of the colors present in Piet, which deter...
[Question] [ # Cell Phone Keyboard Typing [This question](https://codegolf.stackexchange.com/questions/42465/create-a-t9-keyboard) was asked a while back, but was closed due to poor specs. So, I'm redoing it, with better specs. [This question](https://codegolf.stackexchange.com/questions/32817/calculate-cell-phone-...
[Question] [ > > **Synopsis:** Find characters that are enclosed by `MYPOCKET`. > > > **Example Input** ``` MYPHEIF YFOCKVH MBNDEIF TEUFTMY ESNDUWP KBOVUVO CENWFKC OPYMTEB ``` **Example Output** ``` F BND EUF SNDUW BOVUV ENWF ``` Huh? How did we get that as an output? The "pocket" can sometimes be di...
[Question] [ Your task is to create the given target string. Starting with an string that is empty, you will have to add characters to it, until your string is the same as the one we want. You can either add a character to the end of you string with cost x, or you can clone you string with cost y. What we want is t...
[Question] [ ## Introduction Jonny wants to play Frogger. However, he's not very good. In fact, he will only try to move forward, and only after the platforms have moved. Find out if Jonny's frog manages to reach the end of the path or if it dies on its way. ## Challenge The program will be receiving as input a Fro...
[Question] [ ### Background Three years ago, this guy [Tom Murphy](http://www.cs.cmu.edu/~tom7/) got it into his head to extend the idea of a portmanteau to all words in a language and called this a *portmantout* (*portmanteau* plus *tout* [French for *all*]). Defining English as a list of 108,709 words, he managed...
[Question] [ [(This challenge is very similar, but this current challenge has additional complications.)](https://codegolf.stackexchange.com/questions/48531/ascii-doodling-laser-in-a-box) --- Imagine a 2-dimensional room, where the walls are plated with flat mirrors. Suddenly, a beam of light strikes into the room...
[Question] [ Because it's Saturday (UTC) and I'm hungry, I would like a slice of pizza. I will give you an order and I would like a nice hot [ascii-art](/questions/tagged/ascii-art "show questions tagged 'ascii-art'") pizza. Up to the challenge? ## The Drive-Thru I'll place my order wherever your drive-thru is, whe...
[Question] [ Problem: Slot Machine Hacker from [Facebook Hacker Cup 2011 Round 1B](http://www.facebook.com/hackercup/problems.php/?round=167482453296629) Goal: Shortest code in your favourite language using stdin/stdout. You cannot assume `getRandomNumber` is defined, i.e. your solution has to include a potentially...
[Question] [ The majority function is a boolean function which takes three boolean inputs and returns the most common. For instance if `maj(x,y,z)` is the majority function and `T` denotes true and `F` denotes false then: ``` maj(T,T,T) = T maj(T,T,F) = T maj(T,F,F) = F maj(F,F,F) = F ``` This question concerns wri...
[Question] [ A loop is a pretty simple algebraic structure. It is a tuple **(G,+)** where **G** is a set and **+** is a binary operator **G × G → G**. That is **+** takes two elements from **G** and returns a new element. The operator is also required to fulfill two properties * Cancellation: For every **a** and **...
[Question] [ A lawn is defined as a rectangular field with of one character surrounded by two layers of **visible** whitespace. This means two lines above and twos lines below, and a two space padding on the left (the right has visible whitespace, so you do not need to include it). ```     ||||| ||||| |||...
[Question] [ Given the state of a square Game of Life grid, determine whether it could have evolved from any previous state, or could only have been created. That is, identify whether the state is a ["Garden of Eden" state](https://en.wikipedia.org/wiki/Garden_of_Eden_%28cellular_automaton%29). # Input A square gri...
[Question] [ [Roll cakes](https://en.wikipedia.org/wiki/Swiss_roll) are delicious sweets made with a layer of sponge cake, a layer of cream (or icecream), rolled as a spiral, see [Wikipedia](https://en.wikipedia.org/wiki/Swiss_roll). Your task is to get a non-empty phrase string from standard input, strip the space...
[Question] [ ### Challenge You will be given a positive integer `n` as input. Output should be a pyramid-like sandpile built on the rules specified below: * Each integer "falls" downward from the same initial starting point, like sand falling into a conal-shape. * Numbers greater than the number directly below it w...
[Question] [ # Introduction There is a plantation defined by one big *square-board* like this one: [![enter image description here](https://i.stack.imgur.com/UY6cv.png)](https://i.stack.imgur.com/UY6cv.png) The numbers inside each small square represents its area's value/cash/... The farmer needs help to find the *...
[Question] [ I just had a lesson in school about alkanes and figured it would probably make for a great code golf challenge! Don't worry, it isn't as complicated as it may look! # A Quick Rehash (Please Note: To keep this brief, not all information is 100% accurate.) Alkanes are strings of carbon and hydrogen. Ever...
[Question] [ Your task is simple: Write a program that can be run in two languages. It should be a normal quine (prints its own source code) in language 1, and should be an error quine (generates an error message identical to its own source code) in language 2. This is [code-golf](/questions/tagged/code-golf "show ...
[Question] [ **UPDATE: Added a Python framework to get started.** The space-station has been overtaken by crusher-bots. You must direct as many of our expensive and fragile tech-bots called "rabbits" to an exit teleporter before the station self-destructs, but the crusher-bots are patrolling the corridors. Your pro...
[Question] [ What general tips do you have for golfing in [Starry](https://esolangs.org/wiki/Starry)? I'm looking for ideas which can be applied to code-golf problems and which are also at least somewhat specific to Starry (e.g. "remove comments" is not an answer). Please post one tip per answer. [Answer] # Us...
[Question] [ Alphys, the Underground's Royal Scientist, has finished a prototype for a new puzzle. However, she can't seem to find anyone willing to test it. ### The rules of her puzzle are as follows: The goal is to get to the right side, starting from the centermost tile on the left side. For puzzles with e...
[Question] [ Write a function or program that outputs [Quater-imaginary base](https://en.wikipedia.org/wiki/Quater-imaginary_base) displayed as binary digits. The number base is 2*i*, where *i* is the square root of -1. See [Complex Number](https://en.wikipedia.org/wiki/Complex_number) for more details on *i*. Each...
[Question] [ In the game [Terraria](https://en.wikipedia.org/wiki/Terraria), one of the game mechanics involves building houses so that an NPC can move in. There is a strict set of rules for what counts as a valid house or not. Here is the list of rules: 1. The total area in the house must be at least 60 square til...
[Question] [ In a few British newspapers there is a game known as [Hidato](https://en.wikipedia.org/wiki/Hidato). It is somewhat similar to [Sudoku](https://en.wikipedia.org/wiki/Sudoku), albeit instead of having 1-9 in a line and block, it's about placing numbers such that they connect in order from `01` all the w...