HTML & JS
// Code using Scanner Class
import java.util.Scanner;
class Differ
 {
     public static void main(String args[])
     {
         Scanner scn = new Scanner(System.in);
         System.out.println("Enter an integer");
         int a = scn.nextInt();
         scn.nextLine();
         System.out.println("Enter a String");
         String b = scn.nextLine();
         System.out.printf("You have entered:- "
                 + a + " " + "and name as " + b);
     }
}

Generated URL:

Output:

Enter an integer
Enter a String
You have entered:- 50 and name as Geek
Report Bug