Question: Write one expression that returns true if and only if char c is an arithmetic operator, i.e. +, -, *, / or %.(In Java) (c
Write one expression that returns true if and only if char c is an arithmetic operator, i.e. +, -, *, / or %.(In Java)
(c == '+' || c == '-' || c == '*' || c == '/' || c == '%')
Is this the only way to express the arithmetic operators? And please check if the expression above is correct. Thank you.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
