-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocs.txt
50 lines (41 loc) · 1.71 KB
/
docs.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
-= B++ Docs =-
Grouping expressions and instructions is done through brackets and bbrackets:
Brackets: <function> b <expression> B
Bbrackets: bif <arg> bB <code> Bb or bB <code> Bb boop <arg>
Functions:
brint <arg>: print <arg> to console
bif <arg> bB ... Bb: if <arg> is 0 or below, skip to matching Bb
bB ... Bb boop <arg>: if <arg> is above 0, jump back to the beginning of the loop
<arg1> bis <arg2>: sets variable <arg1> to <arg2>
<arg1> bat <arg2> bis <arg3>: sets array <arg1> at <arg2> to <arg3>
Only words that start with "b" or "B" are allowed in this language, including variable names.
Operations:
<arg1> blus <arg2> -> <arg1> + <arg2>
<arg1> binus <arg2> -> <arg1> - <arg2>
<arg1> bimes <arg2> -> <arg1> * <arg2>
<arg1> bivide <arg2> -> <arg1> / <arg2>
<arg1> bat <arg2> -> <arg1>[<arg2>]
<arg1> biss <arg2> -> <arg1> == <arg2>
<arg1> bore <arg2> -> <arg1> > <arg2>
<arg1> bess <arg2> -> <arg1> < <arg2>
<arg1> band <arg2> -> <arg1> and <arg2>
bot <arg1> -> <arg1> flipped (0 -> 1, 1 -> 0)
binput <arg1> -> input(<arg1>)
bength <arg1> -> len(<arg1>)
Literal Values:
Strings - Surround them with BbB (BbB___BbB): BbBExampleBbB, BbBBogos Binted!BbB
Integers - "BB" + "b"s: "BBbbbbb" -> 5, "BBb" -> 1, "BB" -> 0
For negative integers, subtract zero by a positive one:
-1 -> b BB binus BBb B
-7 -> b BB binus BBbbbbbbb B
Examples:
print("Bogos" + " Binted")
brint b BbBBogosBbB blus BbB BintedBbB B
userInput = input("Give me a string >")
if (len(userInput) > 3) {
print("That's a long string")
}
buserinput bis b binput BbBGive me a string >BbB B
bif b b bength buserinput B bore BBbbb B bB
brint BbBThat's a long stringBbB
Bb