On Jul 24, 10:07 am, Chris Angelico <ros... at gmail.com> wrote: > On Sun, Jul 24, 2011 at 5:58 PM, Frank Millman <fr... at chagford.com> wrote: > > if int(dec) != 0: > > to > > if [_ for _ in list(dec) if _ != '0']: > > if dec.rtrim('0')!='': > > ChrisA I think you meant 'rstrip', but yes, neater and faster. Thanks Frank