About Question enthuware.ocpjp.v8.2.1894 :

Help and support on OCA OCP Java Programmer Certification Questions
1Z0-808, 1Z0-809, 1Z0-815, 1Z0-816, 1Z0-817

Moderator: admin

Post Reply
lenalena
Posts: 56
Joined: Tue Feb 21, 2017 4:24 pm
Contact:

About Question enthuware.ocpjp.v8.2.1894 :

Post by lenalena »

Hi! Please, explain what is meant by "automatic variables" in this question.

Thank you!

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

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

Post by admin »

"automatic variables" is just another name for "local variables" that are defined inside a method. You may read more about them here: http://stackoverflow.com/questions/2672 ... ic-in-java

lenalena
Posts: 56
Joined: Tue Feb 21, 2017 4:24 pm
Contact:

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

Post by lenalena »

Got it, thanks!

Deleted User 6318

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

Post by Deleted User 6318 »

two things:
1) I think you cannot use var with int like here, right?

Code: Select all

var int fai = 40;
2) "all automatic variables" in my opinion suggests also automatic variables from other methods, which does not seem to be true

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

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

Post by admin »

1. You are right. int should be removed from there.
2. All sentences of explanatory texts are cannot always be extremely precise, otherwise, it will be the same as the specification! I think in the given context, it is quite clear what it means.

Post Reply

Who is online

Users browsing this forum: No registered users and 18 guests