thanks i try but xx = (double) 816 / (double) 10 or
xx = 816.00 / 10.00 its result 81.599999 ??? --------------------- > hi. > double xx; > xx = 816 / 10 => 81.5999999 ?????????? > it must be 81.60 what is the solution? xx = (double) 816 / (double) 10 or xx = 816.0 / 10.0 The way you wrote it, 816 and 10 are both integers, so 816 / 10 will be an integer division - result 81 You should look at xx = 816 / 10 as two different operations, a divison and an assignment (of the result) - in the 'division' operation it isn't clear that you want the result to be of type double - so the compiler interprets it as an integer division. The result is then assigned (and casted to double) to xx. Good luck, Caspar --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.560 / Virus Database: 352 - Release Date: 08.01.2004 -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.560 / Virus Database: 352 - Release Date: 08.01.2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.560 / Virus Database: 352 - Release Date: 08.01.2004 -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/