Since Integer.parseInt("a") will throw NumberFormatException.
Empty Optional will be returned. and if we try to get() from Empty Optional it results into NoSuchElementException.
So, correct answer is A
upvoted 2 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
aruni_mishra
7 months, 3 weeks agod7bb0b2
1 year agoOmnisumem
1 year, 5 months agotmuralimanohar
1 year, 7 months agoStavok
1 year, 8 months agoRP384
1 year, 12 months agoAnkit1010
1 year, 12 months ago