Q:
try { int x = Integer.parseInt("two"); }
Which could be used to create an appropriate catch block?
Answer & Explanation
Answer: C) NumberFormatException
Explanation: C is correct. 'Integer.parseInt' can throw a NumberFormatException, and IllegalArgumentException is its superclass
View Answer
Report Error
Discuss