• 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
  • Tim Cooke
  • Devaka Cooray
  • Ron McLeod
  • Jeanne Boyarsky
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Martijn Verburg
  • Frits Walraven
  • Himai Minh

K & B book self test concern

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I just read chapter 3 on Assignments and tried the quiz but in question 5 there was a line
int doX (Number n, Number n) {return 4;}

The chapter never mentions a class "Number". Shouldn't it be mentioned before a question uses it?
Thanks
 
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Class java.lang.Number is the root for all wrapper classes i.e Integer, Long, Short ...
 
Ranch Hand
Posts: 229
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This may just be my opionion, but what I felt not only about this book, but perhaps many other books that I have read, they often contain questions where you can't find the exact answer in the book. The book may only cover brief version of the topic, and you have to go online and find whatever resources you can find in order to solve the question. There is also a possibility where there is a sentence or two that you may have skipped while reading. It's hard to say.
 
ahmed yehia
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Regarding this, The book mentioned at the beginning that it assumes you have basic knowledge of Java.
 
Ranch Hand
Posts: 294
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I had a similar gripe as Henry when I went through ch. 3. I was also bitten by that question (I don't go online or things like that when taking the self test). Afterwards, I went back through the chapter looking for occurrences of Number and didn't find it either. I looked it up later and saw it was a superclass. Also, Number is mentioned later in the book.

I suppose you could look at it from the point of view that the real exam assumes you've read the entire book, and in a way the self tests are too, staying in the context of each chapter though.

Could it be a slip up, or, could it be they were trying to teach us a lesson to study the api too evil: .

Aloha,
Doug
[ September 30, 2007: Message edited by: Doug Slattery ]
 
Yeah, but does being a ninja come with a dental plan? And what about this tiny ad?
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic