Tram Line Signal Conflict
To prevent collisions, the SIGNAL must be active only when TRACK1 and TRACK2 are both occupied, but not if the SWITCH is engaged. The ALERT sounds if either track is empty while the switch remains active.
Replay this puzzle All puzzles
The truth table
Inputs on the left, outputs on the right. A circuit solves the puzzle when it reproduces every row.
| TRACK1 | TRACK2 | SWITCH | SIGNAL | ALERT |
|---|---|---|---|---|
| 0 | 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 0 | 1 |
| 0 | 1 | 0 | 0 | 0 |
| 0 | 1 | 1 | 0 | 1 |
| 1 | 0 | 0 | 0 | 0 |
| 1 | 0 | 1 | 0 | 1 |
| 1 | 1 | 0 | 1 | 0 |
| 1 | 1 | 1 | 0 | 0 |
What the table tells you
- SIGNAL is 1 in 1 of the 8 rows, so it is a single AND-shaped condition: one exact combination of the inputs. Every input matters: for each one there is a row where flipping it changes SIGNAL. The rows that turn it on: TRACK1=1, TRACK2=1, SWITCH=0.
- ALERT is 1 in 3 of the 8 rows. Every input matters: for each one there is a row where flipping it changes ALERT. The rows that turn it on: TRACK1=0, TRACK2=0, SWITCH=1; TRACK1=0, TRACK2=1, SWITCH=1; TRACK1=1, TRACK2=0, SWITCH=1.
The smallest known circuit: 7 gates
As a formula, one line per output:
SIGNAL = ((TRACK1 AND TRACK2) AND NOT SWITCH)ALERT = ((NOT TRACK1 OR NOT TRACK2) AND SWITCH)
As a netlist, in the order you would wire it. Each g is one gate; the last lines say which signal drives each output.
g1 = TRACK1 NAND TRACK2g2 = SWITCH NAND SWITCHg3 = g1 NAND g1g4 = SWITCH NAND g1g5 = g3 NAND g2g6 = g4 NAND g4g7 = g5 NAND g5SIGNAL = g7ALERT = g6
The search ran out of budget before it could rule out every smaller circuit, so 7 is the best anyone found, not a proof. If you build it in fewer, the leaderboard records it. Gates that do not feed an output are never counted.
Leaderboard for the day
Nobody posted a result on the day. The circuit above is the reference.
← #26 The Greenhouse Nutrient Pump · #28 The Bakery Cooling Fan →