-
Notifications
You must be signed in to change notification settings - Fork 0
Instructions
Charlotte edited this page Feb 5, 2022
·
2 revisions
So one of the main purpose of any language is to do maths yeah ? So the following instructions are by default implemented in Baguette# Standard Library ( the B#SL ). A number is an integer or a floating point number.
-
CANELE <list of numbers>
returns a number which is the sum of the arguments (if you put a string somewhere in the args it will switch to concatenation of strings for the remaining of the list) -
STHONORE <list of numbers>
same as CANELE but with the standard multiplication -
KOUGNAMANN <number:a> <number:b>
returnsa^b
-
PROFITEROLE <number:a>
returns the square root of a -
FINANCIER <int:n>
returns the nth Fibonacci number as an integer -
PAINAURAISIN <number:a> <number:b>
returnsa-b
-
CHOCOLATINE <number:a> <number:b>
returnsa/b
-
BRETZEL <int:a> <int:b>
returns a random integer in[a,b]
-
BAGUETTEVIENNOISE <number:a> <number:b>
returns the logarithm of a in the base b, soln a/ln b
with ln being the natural log -
OPERA <number:a>
returns-a
-
MILLEFEUILLE <number:a>
returns the floor of a as an integer -
FRAISIER <number:a>
returns the ceil of a as an integer
The language includes IO on the standard output/input and in this section the handling of variables is also included
-
CROISSANT <list of arguments>
prints the arguments separated with a blank character, this list can be non-homogeneous meaning you can print integers,booleans,floats and strings with the same instruction, this instruction also ends with a newline character. -
PAINAUCHOCOLAT <message> <list of replacement>
aprintf
version ofCROISSANT
the placeholder is%d
for everything. -
QUATREQUART <string:name> <argument:value>
create a new variable with the indexname
and assign it the valuevalue
-
MADELEINE <string:name>
offer access to the variable of indexname
throw an exception if the index does not exist -
ECLAIR
read the standard input
yeah i could have call this one "conditions" but it is cooler this way, as stated in Home, the operators are instructions too, they can throw a NON_COMPARABLE exception ( exception handling is not implemented and is not in the short term implementation ideas to do list )
-
TIRAMISU <argument:a> <argument:b>
returnsa==b
-
MERINGUE <argument:a> <argument:b>
returnsa<=b
-
MERVEILLE <argument:a> <argument:b> returns
a<b` -
BRIOCHE <argument:a> <argument:b>
returnsa>=b
-
TARTE <argument:a> <argument:b>
returnsa>b
-
FLAN <argument:a> <argument:b>
returnsa&&b
-
PAINDEPICE <argument:a> <argument:b>
returnsa||b
-
CREPE <argument:a> <argument:b>
returns a XOR b -
CHAUSSONAUXPOMMES <argument:a>
returns not a