A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Java 8 in Action
this week in the
Programmer Certification (SCJP/OCPJP)
regarding arithmetic exception
Joined: Feb 10, 2007
Mar 19, 2007 23:52:00
i thought the ouput would be arithmetic exception finished
but at line 1 i am getting a error cannot convert from arithmeticexception to throwable.can anyone please clear my doubt
Joined: Jul 27, 2001
Mar 20, 2007 00:45:00
i got this output when i ran this program.
: / by zero
I ran jdk 1.4.2_05 version.
Joined: Aug 03, 2002
Mar 20, 2007 00:46:00
You code compiles and runs (on Java 6.0):
>java junk.B1 java.lang.ArithmeticException: / by zero arithmetic exception finished
[ March 20, 2007: Message edited by: Barry Gaunt ]
Ask a Meaningful Question
Getting someone to think and try something out is much more useful than just telling them the answer.
I agree. Here's the link:
subject: regarding arithmetic exception
Doubt in Exceptions.
tricky code snippet
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014