volume_mute

Which method will give a compilation error?

publish date: 2021/06/24 22:22:00 GMT+10

(a)
public boolean isRich(int money) {

   if (money != 0)
     return true;
   else 
      return false;
}

(b)
public boolean isRich(int money) {

   if (money != 0)
     return true;

}

Quizzes you can take where this question appears