input="yes"
while [[ $input = "yes" ]]
do
echo "------------"
echo "Calculator"
echo "------------"
PS3="Press 1 for Addition, 2 for subtraction, 3 for multiplication and 4 for division: "
select math in Addition Subtraction Multiplication Division
do
case "$math" in
Addition)
echo "Enter first no:"
read num1
echo "Enter second no:"
read num2
result=<code>expr $num1 + $num2</code>
echo Answer: $result
break
;;
Subtraction)
echo "Enter first no:"
read num1
echo "Enter second no:"
read num2
result=<code>expr $num1 - $num2</code>
echo Answer: $result
break
;;
Multiplication)
echo "Enter first no:"
read num1
echo "Enter second no:"
read num2
result=<code>expr $num1 \* $num2</code>
echo Answer: $result
break
;;
Division)
echo "Enter first no:"
read num1
echo "Enter second no:"
read num2
result=$(expr "scale=2; $num1/$num2" | bc)
echo Answer = $result
break
;;
*)
echo Choose 1 to 4 only!!!!
break
;;
esac
done
echo "Do you want to calculate again(yes/no):"
read input
echo "Thank you for using this program"
done
Addition (+), Substraction (-), Division ( / ), and Multiplication ( x ).
Parentheses Exponents Multiplication Division Addition Substraction
The definition of "standard algorithm" is that it is a mathematical method used to solve problems such as addition, substraction, division, and multiplication.
The answer will depend on how the information was entered - in pounds (or ponds) or in pennies, what the operations were - addition/subtraction or -multiplication/division).The answer will depend on how the information was entered - in pounds (or ponds) or in pennies, what the operations were - addition/subtraction or -multiplication/division).The answer will depend on how the information was entered - in pounds (or ponds) or in pennies, what the operations were - addition/subtraction or -multiplication/division).The answer will depend on how the information was entered - in pounds (or ponds) or in pennies, what the operations were - addition/subtraction or -multiplication/division).
An abacus is an ancient form of the modern day calculator.
"Parentheses, Exponents, Multiplication and Division, and Addition and Subtraction." Therefore multiplication and division are equal.
above the - and below the division
Division
nope. Multiplication is a form of addition. Division is a form of subtraction.
the fundamental operations in math are, addition +, subtraction -, division /,and multiplication x ..
the inverse of addition is subtraction and the inverse of multiplication is division. Of course, multiplication is just repeated addition so division is just repeated subtraction!
Depending on the complexity of the calculation, a calculator can provide accurate answers more quickly.