yeah that function would help but how would I join both sides again to get a decimal real(float) to round?
for example myfloat = decnum1, ".", decnum2 doesn't work because the string "." isn't a valid int type. how would I join those to be a float again? On Sun, Mar 29, 2009 at 10:46 PM, John Fouhy <j...@fouhy.net> wrote: > 2009/3/30 Chris Castillo <ctc...@gmail.com>: > > that is what I have so far but I need to create a condition where I need > > only 10 sufficient numbers from the variable decnum2. I know I need > > something like > > if len(decnum2) > 11: > > decnum2 = decnum2[0:11] > > Perhaps the round() function will help? > > >>> round(12345, -2) > 12300.0 > > -- > John. >
_______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor