About Question enthuware.ocajp.i.v7.2.1245 :

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
ETS User

About Question enthuware.ocajp.i.v7.2.1245 :

Post by ETS User »

I think there's a problem with the question. If line 3 is removed, the variable i will be undefined for line 4, and so, the code will not compile, as the Option 2 is stating. Therefore, option 2 is correct, is it not?

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

Re: About Question enthuware.ocajp.i.v7.2.1245 :

Post by admin »

Yes, and it is indeed marked as a correct option.

HTH,
Paul.
If you like our products and services, please help us by posting your review here.

dhunziker
Posts: 3
Joined: Wed Aug 07, 2013 4:39 pm
Contact:

Re: About Question enthuware.ocajp.i.v7.2.1245 :

Post by dhunziker »

I think this question is a bit misleading. Asking whether or not the Test class prints 20 in the end. If I'd say that it prints "0 1 2 3 4 5 6 7 8 9 10 9 8 7 6 5 4 3 2 1 20" in the end then that would be correct too. At the same time you could say that if it doesn't print all those numbers in the end the program doesn't work, or at least that any other statement about its output would be incorrect.

If statement number 1 was something like:
"Prints 20 at the end of its output"
"Last number printed is 20"

then, to me, the question would be more accurate.

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

Re: About Question enthuware.ocajp.i.v7.2.1245 :

Post by admin »

The option has now been updated.
Thank you for your feedback.
-Paul.
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 33 guests