package javaapplication1;
import java.io.IOException;
public class JavaApplication1 {
public static void main(String[] args) throws IOException {
String s = "F35";
int n = Integer.parseInt(s);
System.out.println(n);
System.out.println(++n);
System.out.println(n + 12);
}
}
/*
run:
Exception in thread "main" java.lang.NumberFormatException: For input string: "F35"
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at java.lang.Integer.parseInt(Integer.java:580)
at java.lang.Integer.parseInt(Integer.java:615)
...
*/