The Num Stack Arithmac programming language.
Project description
Num Stack Arithmac
Install via:
pip install num-stack-arithmac
Pre-execution
Input is given by specifying the start number.
Instructions
Here are the different instructions:
+
increments the number.
-
decrements the number.
%
performs reduction modulo 2 on the number.
^
squares the number.
r
takes the square root of the number.
p
prints the decimal representation of the number.
q
prints the character with the codepoint of the number.
b
prints the binary representation of the number.
x
prints the hexadecimal representation of the number.
o
prints the boolean representation of the number.
<
starts a comment. Comments are ignored by the compiler.
>
ends a comment. Comments are ignored by the compiler.
s
halts the programme.
All other characters are no-ops. If you use \\
or .
in your programme, the compiler will incorrectly think you are specifying the file path if you are typing in raw code. You can also access a graphical editor by typing in g
.
Example
Here is an example programme that checks whether a number is even or odd (the number is given by the starting value):
%+%o
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for num_stack_arithmac-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9ac7653765106c9584f961e11a185fc24f5ea75a3d8b15608a0c7b9c9f65368d |
|
MD5 | b3fc9c1d9381a67ecda8e2cdbce690cc |
|
BLAKE2b-256 | 5e72d5afaa17b55b5a54cace817ff4cb9a9a33a1f8cba73e0f69f3d74bfbfd40 |