Questions tagged [code-challenge]

A code challenge is a competition for creative ways to solve a programming puzzle with an objective winning criterion not covered by other scoring tags (e.g. code-golf).

Filter by
Sorted by
Tagged with
8
votes
4answers
331 views

Wordle solver challenge

Wordle is a daily online word game that has received considerable attention recently. The Game The object is to guess a secret word in the fewest attempts. Consider the following instance of the game: ...
-10
votes
10answers
146 views

Find the square of a number [duplicate]

Your task is to find the square of a number without using the multiplication sign or division sign However, to make this even trickier, no use of any addition sign or even the minus sign can be used ...
-6
votes
2answers
82 views

Multiplying numbers [duplicate]

Your task, is simply to multiply 2 integers given in input, separated by a ",". The catch is, you cannot use the multiplication operator "*", even if it is being used differently, ...
21
votes
6answers
755 views
+100

Play the Fruit Box Game

Play the Fruit Box Game Intro Fruit Box is a game consisting of a 10x17 grid of numbers, each between 1 and 9, where the goal is to clear as many numbers as possible in a two-minute time window. In ...
-3
votes
0answers
127 views

Pluralize Some Nouns [closed]

Take an input of a noun or list of nouns (your choice), and return the plural form of that word. Your program will be scored on the list of 4205 words below, which are all the words in the google-...
16
votes
1answer
510 views

Largest SKI output in less than 200 combinators

The Challenge Create an terminating expression in SKI Combinator Calculus in less than 200 combinators (S, K, I) that reduces to the expression with the most combinators. There will be no limit on how ...
16
votes
11answers
662 views

Kolmogorov-simple numbers

If you visit Code Golf often, you may have heard of Kolmogorov complexity. It's usually defined as the amount of bytes required to express some string in a programming language. Here the Kolmogorov-...
-1
votes
1answer
178 views

Draw Lines in ASCII [closed]

Challenge Draw lines in ASCII corresponding to given inputs: in the first line there are given size of rows and columns of the view and number of separators between each point in the second line is ...
-1
votes
2answers
151 views

Challenge: create a large number using an esoteric programming language [duplicate]

I enjoy large numbers and esoteric programming language, so I decided to combine them into a programming challenge. Your goal is to push the limits of esoteric languages like BF or Pyth and return the ...
23
votes
11answers
2k views

Infinite ordinals from a well-ordering

Your task is to write a short program that represents a large (infinite) ordinal, using a well-ordering of the set of positive integers. Your program will take two different positive integers and ...
23
votes
6answers
2k views

Write some Genetic Quines

In this challenge, you'll create some programs which behave similarly to genes. When you run one, it will return one of its two "alleles" (a half of its source code), and concatenating any ...
11
votes
7answers
985 views

Iterative Quine

Create a program which prints itself, followed by an additional program. This additional program should print the first program, itself, and then a third program. This continues until the nth program, ...
10
votes
2answers
773 views

Let's go for a rollercodester ride

Let's go for a rollercodester ride The objective of this challenge is to create a program that is run recursively through several languages of your choice. The output of the first iteration becomes ...
19
votes
2answers
523 views

Counting and so on

Content You count numbers every day (I think), and most of you know how to count properly, the one next to 1 is 2, and the next ...
9
votes
5answers
369 views

The Most Palindromy Code to Calculate Palindromy Numbers

The string abaaba Is a palindrome, meaning it doesn't change when it's reversed. However we can split it in half to make two palindromes ...
23
votes
8answers
5k views

Make a Hello World using as many bytes as possible

Write a program that outputs the exact string: jan ale o, toki! ("Hello, world" but in toki pona to prevent builtins.) with an optional trailing newline. ...
-6
votes
3answers
379 views

Make a GUI window in any language using minimum "different characters" [closed]

I want you to make a gui window like this: * if you're thinking, the [quit] button closes the window in any language using minimum "different" characters.. AND remember that the gui window ...
14
votes
1answer
323 views

Build the widest unsupported bridge with nothing but frictionless blocks

In this challenge you must write a computer program that creates a stack of a thousand identical \$1 \times 1\$ frictionless homogeneous blocks such that each block is supported and the stack is ...
21
votes
4answers
2k views

A quantum quine

Your challenge is to write a program that is a quine, meaning it prints out its own source code. For at least one individual character, when it is removed from the program's source, a single different ...
15
votes
18answers
3k views

It almost works (Robbers' Thread)

Cops' Thread Your challenge is to find an uncracked, unsafe cop on the cops thread, and find an input value for which their code does not do as specified by the challenge. You must use values within ...
10
votes
7answers
443 views

Splinter metagolf

The language Splinter is an esoteric programming language where data is stored in 'splinters'. There are three different types of syntax: Simple character output: ...
4
votes
3answers
390 views

Will the hydra finally die? Part II

Background This is a follow up question to the question: Will the Hydra finally die? As before a dangerous A Medusa have released a dangerous Hydra which is revived unless the exact number of heads it ...
5
votes
2answers
275 views

Generate the shortest regex to match these but not those [closed]

Challenge Given two lists of strings where each string is of length 50 and each list is also of length 50 generate the shortest regex you can that fully matches all the strings in the first list and ...
6
votes
10answers
3k views

The worst ever phone number entry screen

The name of the challenge was prompted by this GIF and the GIF also gave me the idea. Your challenge today is to take a input guaranteed to be \$2<=n<=100\$ and output a sequence of ...
12
votes
13answers
683 views

Minimal distinct character quine

Your challenge is to construct a proper quine using as few distinct characters as possible. Scoring Your score is equal to the number of distinct characters in your code, aiming to minimise this. ...
8
votes
8answers
691 views

Encode a Lenguage

The Len(language,encoding) family of languages is a variety of Lenguage derivatives. To encode a program into a Len language, you replace every character with its representation in a certain encoding, ...
8
votes
3answers
345 views

Polyglot Interpreters

Challenge Choose any number of languages. Call this set L. Write a program so that running it in any language in L produces an interpreter for a different language ...
35
votes
29answers
4k views

Concatenated halting problem: no + no + ... = yes

Challenge Write \$2 \le n \le 10\$ distinct, valid non-halting full programs in your language of choice. If all of them are concatenated in order, the resulting full program should be a valid halting ...
18
votes
10answers
2k views

Make a polyglot generator

A polyglot is a program that runs in several languages. Your challenge is to: Choose at least two languages (Different versions count as different languages) Create a program or function that takes ...
21
votes
74answers
4k views

Compose a song, line by line

It's time for CGCC to demonstrate our musical talent! In this challenge, you're going to compose songs while keeping your byte count as small as possible. On Day 0, multiple answerers will post a ...
7
votes
0answers
297 views

Leave a wake of dead cells behind you

Conway's Game of Life is a well known cellular automaton "played" on an infinite grid, filled with cells that are either alive or dead. Once given an initial state, the board evolves ...
7
votes
2answers
314 views

Largest Compatible Maze

Background Consider an \$n\times n\$ grid, where each cell is either empty (denoted by .) or a wall (denoted by #). We say that ...
30
votes
23answers
9k views

R.E.P.A.I.R. T.H.E. K.E.Y.B.O.A.R.D

Sequel of this AWESOME challenge You, a genius tech prodigy detective, have successfully disarmed the bomb and want to break into the computer. The police found the password ...
48
votes
7answers
6k views

Reverse Zip Bomb

A zip bomb is a compressed file, designed so that unpacking it yields the biggest file possible. These are fairly well known, and there are examples of 42 KB files which expand into multiple petabytes ...
6
votes
1answer
292 views

Two Diehards Make a Glider

In Conway's Game of Life, there is an infinite square grid of cells, each of which is alive or dead. The pattern changes each "generation". A dead cell with exactly 3 live neighbors (...
15
votes
5answers
689 views

Keep PPCG running in Game of Life

Conways' Game of Life is a well known cellular automaton "played" on an infinite grid, filled with cells that are either alive or dead. Once given an initial state, the board evolves ...
5
votes
1answer
307 views

2D Pathfinding with Momentum

You are piloting a spaceship, outfitted with an engine that can accelerate you at 1km/s^2 in the direction the ship is facing (you have very good inertial dampers). You also have thrusters which can ...
32
votes
3answers
3k views

Minimally destroy CGCC in Game of Life

Inspiration Conway's Game of Life is a well known cellular automaton "played" on an infinite grid, filled with cells that are either alive or dead. Once given an initial state, the board ...
33
votes
18answers
3k views

Find the HTTP status code

Given the name of an HTTP status code, such as OK or Continue, output or return the corresponding number. Your code is limited ...
11
votes
15answers
2k views

Alphabet printing challenge

This challenge is related Challenge Your task is to write as many programs/snippets as you can, where each one outputs/prints/ returns an alphabet. The first program must output the letter ...
18
votes
7answers
1k views

Square root multiples

This code-challenge is based on OEIS sequence A261865. \$A261865(n)\$ is the least integer \$k\$ such that some multiple of \$\sqrt{k}\$ is in the interval \$(n,n+1)\$. The goal of this challenge is ...
2
votes
0answers
332 views

Make a QR quine [closed]

A "qruine" if you will :) Design a QR code that legibly spells with its pixels (or the space between them) the text that it scans to. For example, this QR code scans to the letter A, and ...
23
votes
10answers
3k views

Pangram "Hello, World!"

Your challenge: The code must print "Hello, World!" and nothing else. Your restrictions: Your program must satisfy these requirements: The program must be a pangram. It must use every ...
7
votes
1answer
352 views

Identify the Kaomoji!

Background This is loosely based on the now closed Kaomoji question asked a few hours ago. Kaomojis are sequences of characters designed to express a given emotion. In this code-challenge, you'll be ...
13
votes
12answers
923 views

Definite integral of polynomial functions

You will need to evaluate the definite integral (bounded by \$a\$ and \$b\$) of a certain polynomial function that takes the form of: $$\int_a^b \left( k_n x^n + k_{n-1} x^{n-1} + \cdots + k_2x^2 + ...
2
votes
0answers
223 views

How long to paint this house? [closed]

Here is the problem, for which I can only think of an iterative solution and have not found a closed formula: You need to paint a house with R rooms. For each room there are four walls and one ...
3
votes
5answers
435 views

Largest Error Message in 100 bytes [duplicate]

The goal is to raise the error message with the most bytes! The error message may not be generated by the program itself, such as Python's raise. errors that do not ...
2
votes
0answers
118 views

Compute the minimal and maximal subset of a set of sets [closed]

Let S be a set of sets, for example S = {{A},{B},{A,B}}. A maximal subset, Max, is an element of S such that no other set in S ...
9
votes
2answers
738 views

Smallest image containing one of every RGB color

I'm not sure if this kind of golf is allowed, but here it is. Your objective is to create an image containing one pixel of every possible RGB color. The image with the smallest file size wins. Rules: ...
4
votes
0answers
182 views

5 tasks in (modified) BrainF**k from the Estonian OI [closed]

Introduction This challenge appeared in the 2020 Estonian Open Informatics Olympiad and was created Sandra Schumann. I thought it was interesting because it involves symmetry and is quite hard even to ...

1
2 3 4 5
18