aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Inquisition Quiz related query Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Inquisition Quiz related query" Watch "Inquisition Quiz related query" New topic
Author

Inquisition Quiz related query

Kshitija Mitter
Greenhorn

Joined: Mar 03, 2008
Posts: 11
Hi,



The correct answer listed is Compilation fails.
But I dont see any problem in the code. It compiles fine and gives null as the answer...
[Hope this is the correct forum for discussing the inquisition related problems]
Swapnil Sonawane
Ranch Hand

Joined: Jan 02, 2008
Posts: 190
Surprisingly, compiles on my Java SDK 5.0


Swapnil S. Sonawane<br /> <br />B.Tech (Expected May 2009)<br />Computer Science, NIT Durgapur, India<br />SCJA 1.0
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14111
    
  16

Is that quiz for Java 1.4 or for Java 5 or newer? This would not compile on Java 1.4, because the "..." (variable number of arguments) is a new feature of Java 5.

On Java 5 or newer it compiles and works without problems and produces null. It's possible that the test contains an error.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
Deepak Bala
Bartender

Joined: Feb 24, 2006
Posts: 6661
    
    5

As Jesper pointed this out, JDK 1.4 does not allow that syntax.

What version of the exam is the mock exam for and how was the question framed ?


SCJP 6 articles - SCJP 5/6 mock exams - More SCJP Mocks
Kshitija Mitter
Greenhorn

Joined: Mar 03, 2008
Posts: 11
It is for SCJP 5 quiz...
[ June 05, 2008: Message edited by: Kshitija Mitter ]
Deepak Bala
Bartender

Joined: Feb 24, 2006
Posts: 6661
    
    5

Originally posted by Kshitija Mitter:
It is for SCJP 5 quiz...

[ June 05, 2008: Message edited by: Kshitija Mitter ]


ah ! then this question must be corrected. Try contacting the author about it
Matt Russell
Ranch Hand

Joined: Aug 15, 2006
Posts: 165
Sorry, my fault -- Mark (the author of those questions) sent me a correction for this a fair while back but I overlooked it. It'll be fixed pretty soon.


Matt
Inquisition: open-source mock exam simulator for SCJP and SCWCD
Matt Russell
Ranch Hand

Joined: Aug 15, 2006
Posts: 165
Just to follow up, this is now fixed in the latest version of Inquisition.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Inquisition Quiz related query