aspose file tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes == primitive Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Groovy Fundamentals video training course this week in the Groovy forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "== primitive " Watch "== primitive " New topic
Author

== primitive

Shiva Mohan
Ranch Hand

Joined: Jan 05, 2006
Posts: 481
I have a basic question.


widening conversion happened to the long at lin5 .so long is changed to double before == test.But when i printed out the x value that is giving only long value.(not giving double value)Why?
Marcos R Oliveira
Ranch Hand

Joined: Apr 20, 2002
Posts: 51
When long is changed to double before == test, it does not change the x type, nor this long is assigned to anything.
[ January 18, 2007: Message edited by: Marcos R Oliveira ]

SCJP 1.4 - SCJP 1.6 - SCWCD in progress
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: == primitive