2009/3/30 Chris Castillo <ctc...@gmail.com>: > 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?
The easiest way would be to convert decnum1 and decnum2 into strings, join them together, and then call float() on the result. e.g. myfloat = float('%s.%s' % (decnum1, decnum2)) -- John. _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor