Write a java program to print a number from the user

Write a java program to print a number from the user. In the Java program, print the value obtained from the user.  This is the first step in learning,  how to print a number in the Java programming language. For beginners, these are the simple java program to print and how to run them in java. For more basic programs in java.

import java.util.Scanner;
public class Main
{
public static void main(String args[])
{
int number;
Scanner scan = new Scanner(System.in);
System.out.print("Enter the number ");
number = scan.nextInt();
System.out.print("Entered number " +number);
}
}

Output:
Enter the number  456               
Entered number 456