About Question enthuware.ocpjp.v8.2.1812 :

All the posts and topics that contain only an error report will be moved here after the error is corrected. This is to ensure that when users view a question in ETS Viewer, the "Discuss" button will not indicate the presence of a discussion that adds no value to the question.

Moderators: Site Manager, fjwalraven

Post Reply
mtrikannad
Posts: 11
Joined: Mon Jan 18, 2016 4:35 pm
Contact:

About Question enthuware.ocpjp.v8.2.1812 :

Post by mtrikannad »

Isnt it possible for this code to generate NullPointerException if console is not available ?

Regards

Mahesh

admin
Site Admin
Posts: 10388
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.ocpjp.v8.2.1812 :

Post by admin »

Yes, it is possible. Generally, you can assume that whenever a question asks you to compile and run a program, it is asking you to do so from the command line. So the console will be available.
Even so, the problem statement has now been updated to say, "What will happen when it is compiled and run from the command line?" This should take care of the ambiguity.

thank you for your feedback!
Paul.

Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests