write a program in java to input a number from the user and print it
Answers
Answered by
2
..
I also want this... plz anyone
Answered by
1
import Java.util.Scanner;
Class InputNumber {
public static void main(String[] args)
{
int number;
System.out.println(“Enter the number:”);
Scanner sc = new Scanner(System.in);
number = sc.nextInt();
System.out.println(number);
}
}
Class InputNumber {
public static void main(String[] args)
{
int number;
System.out.println(“Enter the number:”);
Scanner sc = new Scanner(System.in);
number = sc.nextInt();
System.out.println(number);
}
}
Similar questions
Science,
6 months ago
Social Sciences,
6 months ago
Physics,
1 year ago
English,
1 year ago
Sociology,
1 year ago