unreported exception java.lang.Exception; must be caught or declared to be thrown
Euclid euc = new Euclid();
^
unreported exception java.lang.Exception; must be caught or declared to be thrown
euc.methodEuclid(arrayArgs);
^
2 errors
Below is my code...what's wrong with it..
In my Euclid class already throws exception ...please help me
Expand|Select|Wrap|Line Numbers
- try
- {
- BufferedReader inputA = new BufferedReader (new FileReader("A.txt"));
- BufferedReader inputB = new BufferedReader (new FileReader("B.txt"));
- for(int ind=0; ind<2;ind++)
- {
- lineA = inputA.readLine();
- lineB = inputB.readLine();
- String a = lineA;
- String b = lineB;
- String[] arrayArgs = new String[] { a, b};
- Euclid euc = new Euclid();
- euc.methodEuclid(arrayArgs);
- }
- } catch (FileNotFoundException e)
- {
- e.printStackTrace();
- }
- catch (IOException e)
- {
- System.out.println("There was a problem creating/writing to the temp file");
- e.printStackTrace();
- }