Shawn Lo

Greenhorn
+ Follow
since May 28, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Shawn Lo

class Foof {
final int whuffie;

Foof(){
whuffie = 42;
}

}

The Foof() in line 4 looks strange. I know it cannot be a method, because it does not have public/private, it does not have void or non-void.
So, what is it?

Thanks you.
18 years ago
Dear All:

I am reading Head First Java 2nd Edition Page 332, and I have a question.

Paragraph 2, "A ShirtException catch is big enough to take a TeeShirtException or a DressShirtException(and any future subclass of anything that extends ShirtException)."

I think A ShirtException catch is a big enough to take a TeeShirtException AND a DressShirtException. TeeShirtException and DressShirtException both extend ShirtException, so ShirtException should be big enough to take both TeeShirtException and DressShirtException. But, Since TeeShirtException already has a unique exception for itself, it will not go in ShirtException.

I am confused here. Could anyone help me?

Thank you.
18 years ago
Thanks, Pavel:

Trying to understand can be a good start, don't you think so?
I am new to Java, and wonder if I should take CX-310-055 or CX-310-035?

I know CX-310-055 is for Java 5.0, and CX-310-035 is for Java 1.4.

How strange: According to Sun's website, Java 5.0 = Java 1.5. Why jumping from 1.4 right to 5.0?