Very basic question

Sengly Sengly.Heng at gmail.com
Tue Dec 23 05:46:20 EST 2008


Hello all,

I would like to calculate a string expression to a float. For example,
I have ('12/5') and I want 2.4 as a result. I tried to use eval but it
only gives me 2 instead of 2.5

Help!!!

Regards,

Sengly



More information about the Python-list mailing list