wood burning stoves 2.0*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes what is compile time constant? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "what is compile time constant?" Watch "what is compile time constant?" New topic
Author

what is compile time constant?

rohit shekhar
Ranch Hand

Joined: Mar 05, 2010
Posts: 32
The case constant must be a compile time constant!

Code :-

Q. Both variables are being initialized before use. And I think both have value before compilation. Then why b is not compile time constant.

Ref. SCJP java 6 study guide. Page 336
Rameshwar Soni
Ranch Hand

Joined: Feb 03, 2011
Posts: 247
There is a good post from Henry Wong about What is compile time constant and it is here
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: what is compile time constant?
 
Similar Threads
switch question
assignment problem
Switch case logic
constant inside the switch case
compile time constant