
Correct the Code
13. The following Java application should display a String input by the user:
1 import java.util.Scanner;
2 public classPrintStringTest
3{
4 public static void main( String args[] ) {
5 printString();
6}
7public void printString()
8 {
9 Scanner input = new Scanner( System.in );
10String value;
11 // obtain user input
12 System.out.println("Enter a string: " );
13 value = input.nextInt(); // input string from user
14
15 // call method addString to return output
16 System.out.println("hello" );
17 } // end method printString
18 }// end class PrintStringTest
الخطأالاول في الكود انو بعد النكست مانحط int اما نشيلها او نحط بدلها line ...الخطأ الثاني يمكن انه الكول حق الميثود صح وإلا لا