https://github.com/grandmoff100/beetlelang
A programming language written in hex pairs.
https://github.com/grandmoff100/beetlelang
Last synced: 7 months ago
JSON representation
A programming language written in hex pairs.
- Host: GitHub
- URL: https://github.com/grandmoff100/beetlelang
- Owner: GrandMoff100
- Created: 2021-11-24T01:04:42.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-08-23T21:17:00.000Z (about 1 year ago)
- Last Synced: 2025-01-23T12:15:22.622Z (9 months ago)
- Language: Python
- Homepage:
- Size: 10.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# BeetleLang
Beetle is simple language written in two digit hex pairs.
## Installation
## Usage
### Hello World
Printing "Hello World!" in Beetle is the following`ff 02 0c 48 65 6c 6c 6f 20 57 6f 72 6c 64 21`
## Syntax Rules
### Printing
`ff `Outputs the object or expression.
**Example**
`ff 01 02 10 00`Prints `4096` because `1000` in base 16 is `4096`
### Integers
`01 ... `Creates an integer object out of hex pair digits
**Example**
`01 02 a1 01`An integer with two pairs interpreted as `a101`.
First hex pair, marks this as an integer expression.
Second pair, tells beetle how many more hex pairs to interpret as digits after it.
Third and fourth pairs, are concatenated into a hex number and intepreted in base 16.### Operations
#### Adding
`10 `Returns the first expression added with the second expression
#### Subtraction
`11 `Returns the first expression minus the second expression
#### Multiplication
`12 `Returns the first expression multiplied by the second expression
#### Dividing
`13 `Returns the first expression divided by the second expression