CARVIEW |
Select Language
HTTP/2 200
date: Sun, 27 Jul 2025 22:34:56 GMT
content-type: text/html; charset=utf-8
cf-ray: 965f9b5dec28c174-BLR
cf-cache-status: DYNAMIC
cache-control: private
set-cookie: prov=3bf92df5-8a10-4a39-95e3-d8efe40ded88; expires=Mon, 27 Jul 2026 22:34:56 GMT; domain=.stackexchange.com; path=/; secure; httponly
strict-transport-security: max-age=31536000; includeSubDomains
vary: Accept-Encoding
content-security-policy: upgrade-insecure-requests; frame-ancestors 'self' https://stackexchange.com
x-clacks-overhead: GNU Terry Pratchett
x-frame-options: SAMEORIGIN
x-request-guid: 3d934eb1-c363-4c72-af4e-8d5788088c6d
x-worker-origin-response-time: 1345000000
x-dns-prefetch-control: off
set-cookie: prov=3bf92df5-8a10-4a39-95e3-d8efe40ded88; Path=/; HttpOnly; Domain=stackexchange.com
set-cookie: __cf_bm=R2dUzGRdstFJvU2Jqq6PmFHon2bhPlQQSRUycAvC9wM-1753655696-1.0.1.1-TFIT76EwhukzjLAwQjWmkJ2uDG58GNsOWm2P9vJEf35y4HIJThEAHNy6Yyyq3RXiKvUyxpZoXt3S6_aiT78KDFcX4tRe_IKzMnx7cUS4u6M; path=/; expires=Sun, 27-Jul-25 23:04:56 GMT; domain=.stackexchange.com; HttpOnly; Secure; SameSite=None
set-cookie: _cfuvid=BbTuslRFKVdG9LQwKa5XPYxZNG3sQLDIXrqODg7rFgM-1753655696385-0.0.1.1-604800000; path=/; domain=.stackexchange.com; HttpOnly; Secure; SameSite=None
server: cloudflare
content-encoding: gzip
Newest 'decision-problem' Questions - Code Golf Stack Exchange
Skip to main content
Stack Exchange Network
Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Visit Stack ExchangeTeams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about TeamsQuestions tagged [decision-problem]
For challenges which involve deciding whether or not the input meets certain criteria, and outputting some data, representing that decision.
796 questions
- Bountied 1
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
22
votes
15
answers
2k
views
Write two very different programs with the same characters
Your task is to write two programs/functions, in the same language.
Program 1: Verify that two inputs are anagrams of each other.
Program 2: Verify that two inputs differ from each other at every ...
11
votes
3
answers
2k
views
The shortest NP-complete problem
Find an NP-complete problem that covers all finite ASCII strings, and present a solver for the problem in the programming language of your choice.
By the definition, if there is a finite ASCII string ...
26
votes
38
answers
3k
views
+100
Does your source code contain this character?
Given a character as input, determine if your source code contains that character or not.
Shortest code wins. Though, I'd like to see some "normal" languages too.
UPDATE: the question ...
7
votes
9
answers
498
views
The Array Walker (part 2)
The Array Walker (part 2)
Input: A non-empty array of integers (without nesting1). This can have negative values!
Output: A boolean value2 indicating whether we can reach the end of the array when ...
7
votes
22
answers
795
views
Can we escape from array?
Can we escape from the array?
Input: A non-empty array of non-negative integers (without nesting1).
Output: A boolean value2 indicating whether we can reach the end of the array when starting from the ...
9
votes
3
answers
593
views
Intersection check in the fewest operations
Challenge
Given two line segments, your goal is to write a function which determines if they intersect using only the operations given below:
Multiplication: x*y
...
3
votes
2
answers
189
views
Winding a Queue
You will be given a matrix. It contains a ride exit (with a direction), some path, as well as some obstacles. Your goal is to build the longest possible queue line in that space, which connects the ...
13
votes
7
answers
862
views
Traverse the list
Update 2025-06-04: Thanks for the submissions everyone! It seems like a lot of the solutions are quite slow / timeout for the 100 length test case, so I don't think any will be able to do the 10k. ...
16
votes
12
answers
4k
views
A broken clock is right n times a day
You will be provided with a string containing a digital clock. You must determine how many times per day that clock could be correct. You can ignore daylight savings time. You do not know if the clock ...
7
votes
4
answers
666
views
Ray's intersecting lines
Ray has created some ASCII lines which he is using to draw with on a canvas.
His canvas can be any width and height between 1 to 100 characters (the borders do not count towards these dimensions). He ...
13
votes
17
answers
2k
views
Is it a product of 4 unique primes (A046386)?
A046386 is the sequence of all natural numbers that are the product of exactly 4 distinct primes.
Write the shortest program, function, or code snippet, that, when given a natural number, outputs ...
8
votes
2
answers
185
views
Primitive words
Given a list of values, 1, 2, -1, or -2, we will allow the following simple moves:
Remove adjacent values which are negatives of each other. e.g. ...
15
votes
6
answers
500
views
Block covered cycles
Given a cycle of non-zero numbers we say a "block" is a substring appearing immediately after \$n\$ and immediately before \$-n\$, which contains neither \$n\$ nor \$-n\$.
Here is an example ...
12
votes
4
answers
1k
views
Who's that evolution?
Given two first generation pokemon names as input, write a function (or a whole program) that outputs a Truthy value if the second one is an evolution of the first one (and a Falsy value otherwise).
...
12
votes
14
answers
1k
views
Decide Equality of Closed Surfaces
Objective
Given two closed surfaces (a.k.a. closed 2-manifolds), decide whether they're homeomorphic.
Introduction
In lay terms, a closed surface is a finite-sized shape that resembles a flat plane ...
Welcome to Code Golf and Coding Challenges Stack Exchange! This is a site for recreational programming competitions, not general programming questions. Challenges must have an objective scoring criterion, and it is highly recommended to first post proposed challenges in the Sandbox.
- The Overflow Blog
-
-
- Featured on Meta
-
-
Related Tags
code-golf × 772
string × 147
number × 97
math × 92
array × 70
grid × 47
number-theory × 43
integer × 39
primes × 36
graph-theory × 33
sequence × 29
game × 29
matrix × 29
ascii-art × 25
geometry × 21
chess × 20
parsing × 19
restricted-source × 18
arithmetic × 18
code-challenge × 16
subsequence × 15
binary × 14
combinatorics × 12
palindrome × 12
card-games × 12
more related tags
Hot Network Questions
- Why did the Holy Spirit send Jesus to the wilderness to be tempted by Satan?
- Interface boundary condition and displacement current between two media
- Why is time reversal not a natural part of the Galilean group?
- Time Machine backup disk not writeable any longer
- What does "enter the hold at arden" mean
- Mac Pro 2008 almost dead
- Shimano 105 ST 5500 compatible with a triple front derailleur
- How do Japanese people understand the reading of a single kanji with multiple readings in their everyday life?
- Are you required to protect trade secrets revealed to you even if you didn't sign an NDA?
- Dynamics from iterated averaging
- What were the two colored keys on a MUPID for?
- How to avoid aligning the top of nested braces in cases environment?
- Not your ordinary affix riddle
- How should one pronounce plural French-derived German words?
- Lower bound on ratio of expected maxima of i.i.d. samples from distribution on [0,1]
- How to deter wasps from an untreated larch fence
- Forces applied to a car hood while driving
- Does passive DisplayPort-HDMI adapter work with 4K 60Hz, if host supports DP 1.2 and HDMI 1.4?
- “Unclear step in a math book for entertainment”
- Is there a name for the beat in drum and bass that is a distillation of the amen break
- What is the citation for Augustine's "consensus, non concubitus..."
- I struggle to draft without editing
- What is the weight of holy water?
- "I met a monk and philosopher." How many people did I meet?