1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Exception handling for int variables

  1. Apr 13, 2014 #1
    1. The problem statement, all variables and given/known data

    Handle all possible exceptions for a program that takes two int number from the user and print sum.

    2. Relevant equations

    3. The attempt at a solution

    import java.util.Scanner;

    public class Task1
  2. jcsd
  3. Apr 13, 2014 #2


    Staff: Mentor

    Surely you can write the program that reads two int without exceptions right? we cant help if you dont show some effort.
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted