Lesson 04
Operators
Lesson 04 — Operators
日本語Syntax
Purus replaces symbol operators with keywords, so you never need the Shift key:
| Purus | JavaScript | Meaning |
|---|---|---|
a add b | a + b | addition |
a sub b | a - b | subtraction |
a mul b | a * b | multiplication |
a div b | a / b | division |
a mod b | a % b | remainder |
a pow b | a ** b | exponentiation |
Task
With a be 7 and b be 3, compute sum, difference, product, remainder, and power using the operators above.
Check
npm test 04
Learn more
Loading editor...
Press Ctrl+Enter to run