ID | CMD | Description | Usage |
---|---|---|---|
32 | space | No operation | |
33 | ! | Logical NOT | X! |
34 | " | String mode | 3"str |
35 | # | Skip next command | # |
36 | $ | Copy args[2] | X$ |
37 | % | Modulus | XY% |
38 | & | Binary AND | XY& |
39 | ' | Integer mode | 4'30cf |
40 | ( | If→Skip | X( |
41 | ) | Unless→Skip | X) |
42 | * | Multiply | XY* |
43 | + | Add | XY+ |
44 | , | args[0]→args[1] | , |
45 | - | Subtract | XY- |
46 | . | Fill args with null | . |
47 | / | Divide (floored) | XY/ |
48-57 | 0 - 9 | Number literals | 0 |
58 | : | Shift null args to left | : |
59 | ; | Shift null args to right | ; |
60 | < | Less than | XY< |
61 | = | Equals to | XY= |
62 | > | Greater than | XY> |
63 | ? | Ternary operator | XYZ? |
64 | @ | If→Restart | X@ |
65 | A | Increment | XA |
66 | B | ||
67 | C | Clear output | C |
68 | D | Decrement | XD |
69 | E | Exit program | E |
70 | F | ||
71 | G | ARR Get/Set | XG, XYG |
72 | H | ||
73 | I | Input character | I |
74 | J | ||
75 | K | ||
76 | L | ARR length | L |
77 | M | ||
78 | N | ||
79 | O | Output character | XO |
80 | P | ARR Pop/Push | P, XP |
81 | Q | ||
82 | R | Absolute reverse | XR |
83 | S | ARR Shift/Unshift | S, XS |
84 | T | ||
85 | U | ||
86 | V | ||
87 | W | Wait x milliseconds | XW |
88 | X | Get x | X |
89 | Y | Get y | Y |
90 | Z | Get z | Z |
91 | [ | Forward jump | X[ |
92 | \ | Swap args[1] args[2] | \ |
93 | ] | Backward jump | X] |
94 | ^ | Binary XOR | XY^ |
95 | _ | Random integer | _, XY_ |
96 | ` | Exponent | XY` |
97-102 | a - f | Hexadecimal literals | a |
103 | g | arr Get/Set | Xg, XYg |
104 | h | ||
105 | i | Input integer | i |
106 | j | ||
107 | k | ||
108 | l | arr Length | l |
109 | m | ||
110 | n | ||
111 | o | Output integer | o |
112 | p | arr Pop/Push | p, Xp |
113 | q | ||
114 | r | Relative reverse | Xr |
115 | s | arr Shift/Unshift | s, Xs |
116 | t | ||
117 | u | ||
118 | v | ||
119 | w | ||
120 | x | Set x | Xx |
121 | y | Set y | Xy |
122 | z | Set z | Xz |
123 | { | Binary left shift | XY{ |
124 | | | Binary OR | XY| |
125 | } | Binary right shift | XY} |
126 | ~ | Binary NOT | X~ |
N
ever ERROR
s.
How it works:
- Each character is either a function or a hexadecimal literal 0123456789abcdef
.
- Each time a function is called, it will get up to 3 arguments from results of previous function calls and return a result or null
.
- You have three variables (x, y, z) and two data arrays (ARR and arr) to work with.
- Currently there is no way to add comments, but you can use forward jumps to skip characters, e.g. f3+[This is a comment.
- Only 3 data types are supported: null, signed 32 bit integer, and string.
- The only way to get a string is with the string builder ("), e.g. d"Hello, world!
- Since it's impossible to have errors in Nerror, any random string of characters is a valid program.
- If there is an error, please report the bug to me. Thanks!
The programming language is still in alpha development. Expect bugs.
Many commands will be added and some might be changed.
Nerror v0.2 Copyright © CharCoding 2018, Some Rights Reserved.
Have fun coding!