Linked Questions
15 questions linked to/from Golf all the 16 logic gates with 2 inputs and 1 output!
548
votes
240
answers
132k
views
Showcase of Languages
Notes
This thread is open and unlocked only because the community decided to make an exception. Please do not use this question as evidence that you can ask similar questions here. Please do not ...
230
votes
343
answers
60k
views
Is this number a prime?
Believe it or not, we do not yet have a code golf challenge for a simple primality test. While it may not be the most interesting challenge, particularly for "usual" languages, it can be nontrivial in ...
66
votes
231
answers
17k
views
Add two numbers
Input: Two integers. Preferably decimal integers, but other forms of numbers can be used. These can be given to the code in standard input, as arguments to the program or function, or as a list.
...
46
votes
76
answers
9k
views
Is it a leap year?
This challenge is quite simple. You will take an input which will be a year from 1801 to 2400, and output if it is a leap year or not.
Your input will have no newlines or trailing spaces:
...
20
votes
35
answers
3k
views
Generate a Universal-binary-function Lookup Table
This is tangentially related to my quest to invent an esoteric programming language.
A table of the binary numbers 0 .. 15 can be used to implement a Universal Binary Function using indexing ...
46
votes
11
answers
2k
views
Run Stackylogic
Stackylogic is a logic-based programming language I made up that take in 0's and 1's for input and outputs a single ...
17
votes
21
answers
1k
views
Generate a 6 character string from a 15 character alphabet
In one of our projects at work, we recently discovered a particularly large method for generating a 6 character string from a 15 character alphabet. A few of us claimed "I bet we can get that in one ...
23
votes
2
answers
12k
views
Build a multiplying machine using NAND logic gates
Based on my previous question of the same type, Build an adding machine using NAND logic gates, this time you're being asked to multiply instead of add.
Build a diagram of (two-wire) NAND logic gates ...
36
votes
1
answer
2k
views
Domino Circuits
Scoreboard
Here are the raw scores (i.e. domino counts) for VisualMelon's submission. I'll turn these into the normalised scores described below, when more answers come in. The existing solution can ...
9
votes
3
answers
1k
views
Build a 2-way universal logic processor using NAND logic gates
A 2-way universal logic processor (2ULP) is a network of logic gates that takes two input wires A and B, as well as four other ...
12
votes
2
answers
2k
views
Build a bit-counting comparator using NAND logic gates
A bit-counting comparator (BCC) is a logic circuit that takes some number of counting inputs A1, A2, A3, ..., An as well as inputs ...
10
votes
2
answers
1k
views
Build an EBCDIC converter using NAND logic gates
In this question, a mapping is defined between EBCDIC and a superset of ISO-8859-1.
Your task is to build a network of two-input NAND gates that will take eight inputs ...
16
votes
1
answer
836
views
Build a minifloat adding machine using NAND logic gates
A minifloat is a binary representation of a floating-point number that has very few bits.
The minifloat in this question will be defined as an 6-bit number m, ...
8
votes
1
answer
3k
views
Build an adding machine using NAND logic gates
This is "programming" at its most fundamental.
Build a diagram of (two-wire) NAND logic gates that will take the input wires A1, ...
10
votes
4
answers
417
views
X marks the spot – a print job
Given two numbers, print a page with an "X" in the specified location (±10%).
The numbers must be either percentages or fractions of the page's print area dimensions, e.g. ...