1int result = Integer.parseInt("500");
2System.out.println(result) // prints 500 as int
1 String number = "10";
2 int result = Integer.parseInt(number);
3 System.out.println(result);
4Copy
1 String number = "10";
2 int result = Integer.parseInt(number);
3 System.out.println(result);
4