Solution
-
This was meant to be a trivial problem that all ICS students should be able to complete, it only requires 1 simple if / else statement.
-
// assuming a is the first number, b is the second number and c is the answer.
if(a * b == c){
System.out.println("AC");
} else {
System.out.println("WA");
} -
Time Complexity: O ( 1 ).