bellos/bellos_scripts/basic_math.bellos
2024-10-03 00:14:47 -04:00

41 lines
645 B
Plaintext

#!/usr/bin/env bellos
# File: basic_math.bellos
# Demonstrating arithmetic operations
echo Basic Math Operations
# Simple echo statements for arithmetic
echo Addition:
echo 5 + 3 = 8
echo Subtraction:
echo 10 - 4 = 6
echo Multiplication:
echo 6 * 7 = 42
echo Division:
echo 20 / 4 = 5
echo Modulus:
echo 17 % 5 = 2
echo Compound operation:
echo (10 + 5) * 2 = 30
# Using variables (without arithmetic)
echo Using variables:
a=7
b=3
echo a = $a
echo b = $b
# Simple increments and decrements
echo Increment and Decrement:
echo count = 0
echo count after increment: 1
echo count after decrement: 0
echo Basic math operations completed.