Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Is a RuntimeException "Output"?  RSS feed

 
Steve Norris
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Is a RuntimeException considered to be output? If a main method throws an IllegalArgumentException, would it be correct to say that it ran without output or that IllegalArgumentException was included in the output? Also, do Errors work the same way?

Thanks!
 
Jeanne Boyarsky
author & internet detective
Sheriff
Posts: 37221
519
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's not considered output. By output, the exam means printlns. There will be a separate answer choice about exceptions.
 
Steve Norris
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the answer. I wasn't sure since two explanations in the same practice exam treated them in opposite ways.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!