• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Jeanne Boyarsky
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Liutauras Vilda
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Piet Souris

Wrong Answer for random question, online exam #2 (Java OCA 8 Programmer I Study Guide)

 
Greenhorn
Posts: 21
IntelliJ IDE Oracle Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think the writers have forgotten the new line character on this one.
As is, "7:" is written as a java label, but whose name is an invalid identifier (not alphanumeric, neither starting with $ or _). As is the code doesn't compile.

Please add a newline between line 6 and 7, or accept "G" as the correct answer.

 
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Saad Benbouzid wrote:As is, "7:" is written as a java label, but whose name is an invalid identifier (not alphanumeric, neither starting with $ or _). As is the code doesn't compile.

Please add a newline between line 6 and 7, or accept "G" as the correct answer.


Obviously something went wrong in the "Transform author question to online question" process: a new line character should be added before 7: (and answer E is still the correct answer for this question).

Hope it helps!
Kind regards,
Roel
 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I agree with Roel. The answer is correct, but need a needline.
 
author & internet detective
Posts: 41762
885
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, thank you for pointing out the missing new line. I'll work with the publisher to get it corrected.

My manuscript says this is in exam #2, not #3 by the way.
 
Roel De Nijs
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jeanne Boyarsky wrote:My manuscript says this is in exam #2, not #3 by the way.


Then the publisher made another mistake, because it's definitely in exam #2 (I just took exam #2 in fast-forward mode ).
 
Jeanne Boyarsky
author & internet detective
Posts: 41762
885
Eclipse IDE VI Editor Java
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Actually, it was probably a typo at Saad's end. This thread had online exam #3 in the title. (I just edited it to #2).
 
reply
    Bookmark Topic Watch Topic
  • New Topic