Type alias MinskyRegisterMachineInstruction

MinskyRegisterMachineInstruction: {
    next: number;
    register: number;
    type: "INC";
} | {
    nextIfNonZero: number;
    nextIfZero: number;
    register: number;
    type: "DEC";
} | {
    type: "HALT";
}

Instructions for the Minsky Register Machine. INC increments a register and moves to the next instruction. DEC decrements a register if non-zero and branches accordingly. HALT stops the computation.

Type declaration

  • next: number
  • register: number
  • type: "INC"

Type declaration

  • nextIfNonZero: number
  • nextIfZero: number
  • register: number
  • type: "DEC"

Type declaration

  • type: "HALT"

Generated using TypeDoc