0
JAVA } Error
why does this code return an error? https://code.sololearn.com/ceRnwFcsG9wV/?ref=app
1 Resposta
+ 1
Your method public static boolean div(int num) has return type "boolean" compiler expect that this method will have a "return " statment and it will return some boolean value. You need to replace boolean to void in method declaration if you dont want to return anything. Or return "lab" at the end of the method.