0
Whats wrong with my code?
import java.util.Scanner; public class numbereveorodd { public static void main(String args[]) { int x; Scanner sc=new Scanner(System.in); System.out.println("enter any number:"); x=sc.nextInt(); if (x%2==0) { System.out.println("number is even"); } else { System.out.println("number is odd"); } } }
2 ответов
0
I don't see any problem with your code. What is it that you want to know?
0
While runtime, it got error why bro. Could u please correct me?