Skip to content

Commit 8ece36f

Browse files
authored
Update DOCS.md
1 parent 850eabc commit 8ece36f

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

DOCS.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
# Cubestack Documentation
22

33
## Literals
4-
Unlike sensible languages, literals are econded in base 36, then each digit is mapped to a move on a Rubiks Cube.
4+
Unlike all sensible languages, literals are econded in base 36, then each digit is mapped to a move on a Rubiks Cube. Luckily, there is a converter on the online interpreter.
55

66
For strings, `"hi"` would first become it's ASCII codes, `[104, 105]`, then in base 36, `["2w", "2x"]`, then each of those digits mapped to a move and enclosed in `S` and `S'`, `S R2 B2 R2 b S'`.
77

88
For numbers, the number is just converted to base 36 then has the decimal place (if present) replaced with `M2`. For example `12.34` would become `["c", "y"]`, then each digit mapped to a move, joined with `M2`, and put inside `M` and `M'` resulting in `M U M2 b' M'`. Note that to make a negative number you need to either multiply it by -1 (`M M'`) or subtract it from zero.
99

1010
Lists are notated with `E` and `E'` (the equivelent of `[` and `]`) and `E2` for seperating list items. Note that literal multi-dimenstional lists will be flattened.
1111

12-
Luckily, there is a converter on the online interpreter.
13-
1412
## Math
1513
`R` - Add
1614
`R'` - Subtract (or if one of the arguments is a string and the other is a number, `str.slice(0, -num)`

0 commit comments

Comments
 (0)