Network Headache

From Esolang
Jump to: navigation, search

Network Headache is an esoteric programming language invented by User:Zzo38.

The purpose of this programming language is that all variables are shared with all Network-Headache programs running, everywhere. Every step (a fixed amount of time), a list of all running programs is made, ordered randomly, and one step is executed of each program, in that order. Variable names are all uppercase letters, nothing else. Numbers are infinitely long non-negative integers.

Operators

  • a-b: Subtraction, absolute value
  • a*b: Multiplication
  • a$b: INTERCAL mingle
  • a~b: INTERCAL select
  • a?: (a) XOR (2a). So binary [10010111]?=[110111001] (like INTERCAL)
  • (a): Value of a, used to control precedence.
  • Numbers are in base ten, variable names used anywhere numbers can.

Commands

  • SET a=b: Sets the value of variable a to b.
  • IN a: Reads input, and stores it in variable a.
  • OUT a: Outputs a.
  • SKIP: Skips a command in the next program which will execute a step. Wastes its turn, and its line.
  • LABEL a: Labels the current location as number a.
  • DO a: If the label a exists, push the current location to stack and go to a.
  • FORGET a: Works like INTERCAL forget command.
  • EXIT: Works like INTERCAL DO RESUME #1. If the stack is empty, ends program execution.

External resources