WALP

From Esolang
Jump to: navigation, search

WALP (What A Limited Programming language) is a language designed by User:fr34k in 2008.


Basic WALP description

WALP is a programming language, consisting of a 16*16 "programming-grid", where the program is written. Inside this grid, there are several different static commands, called chunks, which can never be moved. Due to this, programming in WALP is extremely limited. Execution of different commands is done by moving the pointer trough the grid, by using other non-static commands, called flexes, which can be placed wherever inside the grid. When the pointer hits a static command, the command is executed and the pointer keeps moving. WALP has one memory pool represented by a '#', which one can increment, decrement or output. It has a minimum, starting value of 0 and a maximum value of 255. When the pool reaches above 255, it restarts at 0. Not only is # a memory pool, but also a chunk. Its different functions are stated below.

WALP chunks (static commands)

$ - Start of the pointer. From this, the pointer will begin moving right
# - Depending on from where it is hit by the pointer, it does the following
    Left - Increment pool by 1
   Right - Decrement pool by 1
      Up - Output pool
    Down - Empty pool
! - End of program. When the pointer hits this, the program exits

WALP flexes (non-static commands)

@ - Turn the pointer's direction clock-wise
o - While-statement. Depending on the accent of this letter, the while
    has different meanings. If the while-condition is true, the pointer will
    bounce back when it hits this instruction; if false, it will move straight
    through it.
  ó - While the pool is not 0
  ò - While the pool is not 255
/ - Bouncer. The pointer bounces back when it hits this.

Programming in WALP

When you start programming in WALP, you will begin with a 16*16 grid with the 3 chunks, looking like this:

$






       #







               !

This program will loop forever, because the pointer never reaches the exit. Whenever the pointer hits a wall, it will continue moving in the same direction, from the opposite wall.

This program increments the pool 1 time then outputs it and exit:

$        @





    @  @
     @ #  @
     @   @
    @     @
      @        @
      @@



               !

The following program is a loop, constantly incrementing the pool (if someone would like to describe how this works, step by step, please do):

$  @






  @    #
  @@






               !

One of the difficulties when programming in WALP is the execution of a while-statement.

Implementations

walp.rb - Ruby interpreter and graphic debugger by JayCampbell