Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Long to Float conversion

 
malini griddaluri
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All ,
I have a very basic doubt as to how can a conversion from long to float not require any explicit casting or why is it known as widening conversion?
Long is 64 bits and float is 32 bits so doesn't the number get truncated when a cast occurs?
 
Rob Ross
Bartender
Posts: 2205
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic