[Tutor] Breaking down integers?

Mario Rol mario_rol at hotmail.com
Tue Jan 4 09:57:02 CET 2005


First, convert the integer to a string by using str(), then convert the 
string to a list by using list()


>------------------------------
>
>Message: 6
>Date: Mon, 3 Jan 2005 17:17:36 -0500
>From: "kilovh" <kilovh at gmail.com>
>Subject: [Tutor] Breaking down integers?
>To: <tutor at python.org>
>Message-ID: <001a01c4f1e2$08858ed0$2002a8c0 at TSVI>
>Content-Type: text/plain; charset="iso-8859-1"
>
>I would like to be able to take an integer, break it down into individual 
>items in a list, and then put them back together. I know how to do this 
>last part thanks to Orri Ganel and Guillermo Fernandex, but what about 
>taking the integer apart?
>
>Sorry if the questions have incredibly obvious answers, I'm new to this.
>
>~kilovh

_________________________________________________________________
Talk with your online friends with MSN Messenger http://messenger.msn.nl/



More information about the Tutor mailing list