Wednesday, July 09, 2008

Compile-time String Constant

After doing java for so long, and though everytime interview, I like to ask people what does final mean in java. I can still make this mistake when helping a colleague to check what is wrong with his program. How come after he change the constant class and patch into the jar file, the other class is still showing the old constant value ... sigh... I finally solve the mystery ... but couldn't believe that it took me that looo.......oonnnnng ...

Am I getting old?

Pregnancy making me more forgetful? hahaha...

maybe time to sharpen my skills. *sigh*

Still lost as to what I am saying, you can look at the article below:
Compile-time String Constant Quiz

Happy coding and hopefully after reading this, you won't make the same silly mistake as me. :)

1 comment:

安公子 said...

Haha...it is just an oversight for experienced programmers...I think I may also overlooked that...coz that is the least place u expect it to go wrong...

Post a Comment