+ 2
Please help me for correct these program
3 Answers
+ 3
System.out.println("enter name");
Scanner sc = new Scanner(System.in);
String name=sc.nextLine();
System.out.println("no is: " + name);
after you make a new scanner, you have to use it. Line 2 I made a new scanner. Line 3 I used it to assign the input to a variable called name.. then in line 4 I put it into the print method
+ 3
thank you very much.
+ 2
likes my programs if {correct}