About Question enthuware.ocpjp.v7.2.1267 :

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
D3x!

About Question enthuware.ocpjp.v7.2.1267 :

Post by D3x! »

Here, list2 is a list of any thing. You cannot add any thing to it and you can only retriev Objects from it:
I am sure you mean you can add anything to it? not cannot?

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

Re: About Question enthuware.ocpjp.v7.2.1267 :

Post by admin »

No, the given comment is correct.

list2.add(new Object());
and
list2.add("aaa");

will not compile.

HTH,
Paul.

Student
Posts: 53
Joined: Fri Sep 20, 2013 7:20 am
Contact:

Re: About Question enthuware.ocpjp.v7.2.1267 :

Post by Student »

But you can add null though, yes?

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

Re: About Question enthuware.ocpjp.v7.2.1267 :

Post by admin »

Yes, null can be added. It has now been added in the explanation. Thank you for your feedback!

Post Reply

Who is online

Users browsing this forum: No registered users and 8 guests