I use sdk 3.5, g++, mk68. I have three variables
int i = 3;
float f = 2.3;
float g = 1.2;
f += g; // works fine and produces 3.5
// but....
f += i; // produces 2.3
// and...
f += (float)i; // produces 2.3
// and...
f = i; // produces 0, even if I caste
Can anybody explain why this happens, and how I can
convert an integer into a float. I tried looking at float.h
but couldnt really figure it out, and the whole thing looks
horrible :P.
Thank you
Regards Neptun
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
Share information about yourself, create your own public profile at
http://profiles.msn.com.
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/