/monty

Primary LanguageC

Monty Project

0. push, pall

Implement the push and pall opcodes. The push opcode pushes an element to the stack. The pall opcode prints all values on the stack.

1. pint

Implement the pint opcode. The pint opcode prints the value at the top of the stack.

2. pop

Implement the pop opcode. The pop opcode removes the top element of the stack.

3. swap

Implement the swap opcode. The swap opcode swaps the top two elements of the stack.

4. add

Implement the add opcode. The add opcode adds the top two elements of the stack.

5. nop

Implement the nop opcode. The nop opcode doesn’t do anything.