+ 3
4th Sep 2018, 4:41 AM
Prince Verma
Prince Verma - avatar
2 Answers
+ 6
If you want to make it shorter and avoid repetitions, you can replace lines 8-13 with: System.out.println(n%2==0 ? "even" : "odd");
4th Sep 2018, 5:06 AM
Anna
Anna - avatar
0
return n%2==0;
5th Sep 2018, 9:03 PM
Oleksiy FedorchenkođŸ“±đŸ‡ș🇩
Oleksiy FedorchenkođŸ“±đŸ‡ș🇩 - avatar