CARVIEW |
Select Language
HTTP/2 200
date: Sun, 27 Jul 2025 20:37:07 GMT
content-type: text/html; charset=utf-8
cf-ray: 965eeeca6fcfc1c2-BLR
cf-cache-status: DYNAMIC
cache-control: private
set-cookie: prov=634a7794-977d-48b7-9a95-9602c02dda56; expires=Mon, 27 Jul 2026 20:37:06 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: be5da11e-9477-4b7b-9b1e-2edee3554e51
x-worker-origin-response-time: 930000000
x-dns-prefetch-control: off
set-cookie: prov=634a7794-977d-48b7-9a95-9602c02dda56; Path=/; HttpOnly; Domain=stackexchange.com
set-cookie: __cf_bm=gMXNgYYo.4V_v8FHnof4NLMCwgI2eofmCRRr9Y1lQ4k-1753648627-1.0.1.1-om4r_apRE7WI_.RtIBcHiTI9nBX1tGWP5CgWaXTTWRxX7pdb7jPOq5tvKdf4jLKkvBzBz1wzPLXCfYZ.X6qGeaY_dBinauV2UlD3WHWh9Jw; path=/; expires=Sun, 27-Jul-25 21:07:07 GMT; domain=.stackexchange.com; HttpOnly; Secure; SameSite=None
set-cookie: _cfuvid=VaC_cKORKY9UrqnPGRe0WbgUfWfcoOkcYQti09zK7w0-1753648627250-0.0.1.1-604800000; path=/; domain=.stackexchange.com; HttpOnly; Secure; SameSite=None
server: cloudflare
content-encoding: gzip
Newest 'math' 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 [math]
The challenge involves mathematics in some central way. Also consider using more specific tags, listed in the tag wiki info.
1,864 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
23
votes
6
answers
2k
views
Computing Pi with iF*ck
Objective
Compute \$\pi\$ using nothing but \$i\$ (\$\sqrt{-1}\$).
Guidelines
ONLY exponentiation and multiplication may be used (i.e. \$i^i\$ or \$ii\$)
No additional symbols may be used (so no ...
5
votes
10
answers
1k
views
Genshin Elemental Aura Decay
There is this game Genshin Impact, when an element is applied to an enemy i.e. Electro it remains for some time causing decay to the enemy health. For this challenge, we'll simplify this to a single ...
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
...
6
votes
16
answers
1k
views
555 Timer Calculator
The Challenge
In honour of getting 555 Rep, here's a little challenge to work out the frequency of a 555 Timer. The frequency can be worked out using
$$ f=\frac{1.44}{(R_1+2R_2)C_1} $$
Implement this ...
-4
votes
12
answers
278
views
Power Grid Management
You are writing the management software for one "node" of a power grid. A node has a layout like this
+
|
+---N---+
|
+
Each + is a ...
4
votes
8
answers
845
views
How many distinct characters can be used to implement Boolean Algebra in your programming language [closed]
I am interested in the following problem:
What is the minimum number of distinct characters used in any programming language that can implement Boolean Algebra?
In particular, what is the set that ...
8
votes
4
answers
465
views
Ultra-modular representative of rational numbers
Objective
Given a reduced fraction \$p/q\$ where \$q > 0\$, output the (unique) reduced fraction \$p'/q'\$ such that:
\$p'\$ is nonnegative and less than \$q'\$, and
\$q'\$ is a positive odd ...
-10
votes
2
answers
260
views
Fizz-Buzz-Bazz-Pazz
Fizz-Buzz-Bazz-Pazz
Problem Summary
Write a program that prints numbers from 1 to 100 with replacements based on the following ...
-3
votes
5
answers
250
views
Shortest Inverse Square Root [duplicate]
Alex ([email protected]) So... uh, thanks for covering me last time. Look, we've had a pretty odd order from a client, but they're willing to pay a TON to ...
11
votes
5
answers
760
views
Show order equivalence between the rationals and the binary fractions
Write a function \$f\$ which takes rational numbers and gives binary fractions (rational numbers whose denominator is a power of two) which is bijective and preserves order.
That means:
Different ...
16
votes
17
answers
3k
views
Noise Cancelling Headphones
Alex ([email protected]) Hey champ, we've just had a huge order for those new noise-cancelling headphones we're meant to be making. Unfooooorrttunately... ...
8
votes
1
answer
328
views
Ruler-and-compass constructions
In this code-golf challenge, you will work with a construction that was used by the ancient Greeks: the straightedge-and-compass construction. In particular, you will count how many different ...
3
votes
1
answer
228
views
Count number of families of sets satisfying a list of criteria
CHALLENGE
This problem has a math background.
For n=1,2,3,4 we want to count the number of families of sets with maximum n elements that satisfy many criteria of the form:
$$\bigoplus_{k\in A,A\in \...
8
votes
4
answers
226
views
Inequality region vertices with 4 equations
Given the following inequalities:
$$
\begin{align}
ax+by&\leq c\\
dx+ey&\leq f\\
gx+hy&\leq i\\
jx+ky&\leq l
\end{align}
$$
These inequalities enclose a region in the shape of a convex ...
-6
votes
4
answers
331
views
Find the argmin of the cusum
Input
You will be given an array arr of length 10 of float64s. They will all be between -1 and 1.
Output
You must give the index in the array of the minimum value ...
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 × 1679
number × 304
sequence × 247
number-theory × 186
arithmetic × 185
geometry × 131
integer × 98
combinatorics × 97
decision-problem × 92
primes × 89
code-challenge × 78
array × 77
matrix × 71
string × 63
polynomials × 62
rational-numbers × 61
fastest-code × 53
abstract-algebra × 41
ascii-art × 39
open-ended-function × 38
linear-algebra × 38
base-conversion × 37
fibonacci × 30
permutations × 28
restricted-source × 28
more related tags
Hot Network Questions
- I don't have enough alive employees to start the day. What now?
- Not being introduced to the team – should I ask for it?
- How to avoid aligning the top of nested braces in cases environment?
- How do Japanese people understand the reading of a single kanji with multiple readings in their everyday life?
- Is there such a thing as 'aerospace grade software'?
- When was the last time all humans were on the ground not in the air?
- rock paper scissors game with randomized system choices. NOT using rnd()
- Why did the Holy Spirit send Jesus to the wilderness to be tempted by Satan?
- Civilian airplanes with inside fuselage jet engines
- edge to curve endpoint move/transform to normal direction
- Why am I winning always? A coincidence perhaps?
- Testing Hypotheses with Limited Data in an Ecological Experiment. How do I approach my data?
- Why legacy paying method for ZKSync?
- "I met a monk and philosopher." How many people did I meet?
- Will an error in two of my published papers affect my PhD thesis evaluation?
- Why does Timor-Leste call itself a "Democratic Republic" despite little apparent Marxist-Leninist ideology?
- Interface boundary condition and displacement current between two media
- “Unclear step in a math book for entertainment”
- When was thermal expansion in solids first described?
- Anonymizing a submission for double-blind review
- Is there any verse which says that throughout the Vedas the praise of Shiva is sung?
- Are you required to protect trade secrets revealed to you even if you didn't sign an NDA?
- Still learning electronics, can you explain this voltage protector failure?
- Extensions of diagonalizable, respectively multiplicative-type, groups