PDA

View Full Version : How to convert int to float?



babygal
21st June 2010, 04:32
How to convert int to float?

aamer4yu
21st June 2010, 06:06
Are you versed with data types ?
There are some implicit conversions done by the compiler itself.

You can simply use -
float f = i; // i being an integer.