Tim Michelsen wrote: > Hello, > how can I suppress the decimal places for (only those) numbers whos > decimal places are zero (0)?
I don't know how to do this with just string formatting but I think ('%.4f' % n).rstrip('.0') will do what you want. Kent _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor