i36BK

              More words, easier to remember*1:

              MIN:     COPY

              MOORE*2: READ, WRITE

              STACK:   PUSH, POP, DUP, DROP, SWAP

              IL (IEC  LD ST S R AND OR XOR NOT ADD SUB MUL DIV
              61131-3) MOD LT LE QE NE GE GT SHL SHR JMP CAL RET

              RISC: more..
              ..
              CISC: even more..
              ------
              *1) no need to remember state of the automata.
              *2) Moore Automata.


I. COPY "from" "to"
...................

As an example, lets write down some chess game using fictional "geometric notatation\". Talk with angry notation inventor:

  1. What piece moves: Pawn, Rock, kNight, Bishop, Queen or King?
     The one standing on the "from" square.
  2. And what is the color of that chess piece?
     Whites make the first move.
  3. How do i know if piece takes?
     'to' square is not empty.
  4. What about castling (vangerdus, рокировка)?
     King moves two squares.
  5. And .. (interrupting)
     And so on. Opposte to well known "Algebraic notation"
     we can save 4 bits of 16 per move

        chess{'rock'} A1 A8

  required:

     horizontal: (3 bits) 0..'h'-'a'
     vertical:   (3 bits) 0..'8'-'1'

  optional:

     piece:      (3 bits) pawn 001, rock 010, knight 011, bishop 100,
                          queen 101, king 110
     color:      (1 bit)  0 black, 1 white

Compile following game manually:

  1.  е2-е4  е7-е5
  2. Qd1-h5 Nb8-c6
  3. Bf1-c4 Ng8-f6
  4. Qh5:f7#

II. PUSH-POP-DUP-DROP and SWAP (Haiku Forth)
............................................

Estonia
.......

blue
black
white

   0.333 y > dup 0.333 y > 0.666 y < or

China
.....

Red

   1

Russian Federation
....................

white
blue
red

   0.333 y > 0.666 y < or 0.666 y < 0.333 y <

Poland
......

white
red

   1 0.5 y < dup

Russian empire
..................

black
yellow
white

   0.666 y > dup 0.333 y >

Ukraine
.......

blue
yellow

   0.5 y > dup 0.5 y <

Japan
......

(x ** 2 - x + 0.19 = 0
   x1 ≈ 0.2550510257216822
   x2 ≈ 0.7449489742783177)

   1 .5 .06 y .5 - 2 ** - sqrt - x >
   .5 .06 y .5 - 2 ** - sqrt + x < or
   y .255 < or y .745 > or dup

III. x86 -- SOFTWAREFOREDUCATION
--------------------------------

Test traffic lights:

      CLO        ; Close unwanted windows.
      MOV CL,0
  Start:
      PUSH CL
      POP AL
      OUT 01      ; Send AL to Port One (The traffic lights).
      INC CL
      JMP Start
      END

Commands:

  MOV ADD SUB MUL DIV INC DEC AND OR XOR NOT ROL ROR SHL SHR CMP
  JMP JFLAG CALL RET INT IRET PUSH POP IN OUT HALT NOP STI CLI DB

Directives:

  ORG

Specific to simulator

  CLO

Links:
......

  1. https://www.programiz.com/c-programming/c-enumeration

  2. https://forthsalon.appspot.com/

  3. http://softwareforeducation.com/sms32v50/index.php

