Now that we've designed the OR chip, let's design the XOR chip, also known as the "Exclusive Or".
┌───────────┐
IN[0] ●─┤ │
│ XOR ├─● OUT
IN[1] ●─┤ │
└───────────┘
The OR chip has 2 IN pins and 1 OUT pin.
The OUT pin will transmit a powered signal only when the two IN pins are reading different signals.
XOR.IN ║ XOR.OUT
────────║─────────
00 ║ 0
01 ║ 1
10 ║ 1
11 ║ 0
The circuit board will come pre-installed with INPUT and OUTPUT chips as shown below:
───────┐ ┌────────
├─● OUT[0] │
INPUT │ IN ●─┤ OUTPUT
├─● OUT[1] │
───────┘ └────────
Digital Logic Circuit Interface
For these Digital Logic Circuits tasks, you will not be providing an answer string you would for other tasks.
Instead, your Solution Code will be interpreted directly to place chips onto the circuitboard and connect them with wires.
Click here to learn the Digital Logic Circuit Syntax used on this site.
After the chips have been placed and connected, the server will run a series of tests, randomly assigning values to the input pin(s) and checking to see if the output pins read the corresponding expected values. If all tests produce the expected outputs, then the circuitboard is considered a success.
Even though we won't be using the "Your answer" box, you'll still need to put something in that box to submit your solution. Just put anything - it will not be passed to the interpreter.
Truth Table
Design a circuit board which satisfies the following Truth Table:
INPUT.OUT ║ OUTPUT.IN
───────────║───────────
00 ║ 0
01 ║ 1
10 ║ 1
11 ║ 0