About Question enthuware.ocpjp.v8.3.1916 :

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

Moderator: admin

Post Reply
ramy6_1
Posts: 124
Joined: Wed Feb 12, 2014 2:44 am
Contact:

About Question enthuware.ocpjp.v8.3.1916 :

Post by ramy6_1 »

Hello ,

Option 4 is correct and I think it should access /a/a.txt at final step , right ?

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

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

Post by admin »

What happened when you tried it out?
If you like our products and services, please help us by posting your review here.

gloria
Posts: 2
Joined: Fri Nov 11, 2016 11:36 am
Contact:

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

Post by gloria »

I have tried it out and it is printing:

\a
\a\a.txt
\a\b
\a\b\b.txt
\a\c

So the answers for this question are wrong!

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

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

Post by admin »

Why to you think the answer is wrong? Did you read the explanation?
-Paul.
If you like our products and services, please help us by posting your review here.

gloria
Posts: 2
Joined: Fri Nov 11, 2016 11:36 am
Contact:

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

Post by gloria »

As ramy6_1 noticed if the option 4 is correct, the code should also print /a/a.txt which is not mentioned in option 4. I also think it should print \a. I tried it out in eclipse and it is printing:

\a
\a\a.txt
\a\b
\a\b\b.txt
\a\c

the option 4 only gives:

/a/c
/a/b
/a/b/b.tx

so \a and \a\a.txt are missing from option 4. If you think that \a and \a\a.txt won't be printed then please explain why.

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

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

Post by admin »

The question clearly says, "Which of the following options can be a part of possible output generated by the above statement?".

The options are not complete output but only a part of the complete possible output.

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

Tanooki
Posts: 9
Joined: Wed Dec 28, 2016 12:35 pm
Contact:

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

Post by Tanooki »

So it says I should select 1 answer...

But...

A
/a/b - can be part of output
/a/c - can be part of output
/a/b/b.txt - can be part of output

B
/a/b - can be part of output
/a/a.txt - can be part of output
/a/c - can be part of output

C
/a/b/b.txt - can be part of output
/a/c - can be part of output
/a.txt - cannot be part of output

D
/a/c - can be part of output
/a/b - can be part of output
/a/b/b.txt - can be part of output

....? So there are 3 correct answers and I can choose only one!


Tested on Windows, with C:\\a instead of /a
Output:
C:\a
C:\a\a.txt
C:\a\b
C:\a\b\b.txt
C:\a\c

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

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

Post by admin »

The sequence is critical here. If it were not, each line would have been a separate option.
Paul.
If you like our products and services, please help us by posting your review here.

Tanooki
Posts: 9
Joined: Wed Dec 28, 2016 12:35 pm
Contact:

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

Post by Tanooki »

Then the question has to mention "can be part of the output, in this order".

And then still, the correct answer is not there... All of those answers are not part of the output in that order.

Post Reply

Who is online

Users browsing this forum: No registered users and 237 guests