I have problem writing a testcase to this method below: EvenNum(double)
EvenNum(double)
public class OddEven { /** * @param args */ public boolean evenNum(d
Two things :
You are invoking a non-static method statically. The method should be declared static:
public static boolean evenNum(double num) {
}
You didn't type the name of the method correctly. Look closely. Also consider renaming it something more readable like, isEven(...)
isEven(...)