Skip to content

Commit

Permalink
Add documentation on references
Browse files Browse the repository at this point in the history
  • Loading branch information
antonmedv committed Aug 7, 2023
1 parent a318620 commit 811369e
Showing 1 changed file with 18 additions and 6 deletions.
24 changes: 18 additions & 6 deletions DOCS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,21 @@ around your calculations, so that they will make sense later.
$500 for tickets + $70 for a taxi
```

# Formatting
## Formatting

Use `#` symbol at beginning of a line to mark it as a **header**.

Use `:` colon to mark first part of line as **description**.

# Numbers
## Numbers

- `0.5 + .5` - decimal numbers
- `1k` - one thousand
- `1 000 000` - million with spaces
- `1,000,000` - million with commas
- `1M` - million with letter

# Operators
## Operators

Supported operators `+`, `-`, `*` or `x`, `/`, `%`, `^`.

Expand All @@ -32,7 +32,7 @@ Supported operators `+`, `-`, `*` or `x`, `/`, `%`, `^`.
- Percentage subtraction `100 - 25%`
- Percentage calculation `25% of 100` or `100 * 25%`

# Currencies
## Currencies

Numbr can do math with lots of currencies. Currency exchange rates are updated every hour.

Expand All @@ -47,26 +47,38 @@ Numbr supports cryptocurrencies as well:
- `1 eth in doge`
- `10 xrp in ada`

# Sum
## Sum

Numbr can summarize results by using `total` or `sum` operators. Calculations are done up to the nearest header:

```md
## header 1

Milk $3
Eggs $2
Sugar $1
Flour $5
Total

## header 2

100k usd
10 btc
1M chf
Sum
```

# Variables
## References

Numbr supports referencing calculation results. Click on the answer to copy, and paste to reference, or press
*Alt+Enter* to put the current answer on the next line.

```
100 + 200 | 300
(300) + 25% | 375
```

## Variables

Numbr supports variables with `=` operator. Variable names are case-insensitive and can contain letters, numbers and
spaces:
Expand Down

0 comments on commit 811369e

Please sign in to comment.