Re: alphanumeric list

2011-03-16 Thread not1xor1 (Alessandro)
Il 15/03/2011 09:10, yqyq22 ha scritto: I would like to put an alphanumeric string like this one EE472A86441AF2E629DE360 in a list, then iterate inside the entire string lenght and change each digit with a random digit. Do u have some suggestion? thanks a lot hi I'm not an experienced python

Re: alphanumeric list

2011-03-16 Thread Laurent Claessens
string = "EE472B" t = [] for x in string[:]: print t.append("A") #i don't want to append A, the final result is EAEA4A7A2ABA As it, it prints "None" 6 times. Then t is ['A','A','A','A','A'] What you have to do is to read about basic python. Search for python tutorial on the net.

Re: alphanumeric list

2011-03-16 Thread Laurent Claessens
string = "EE472B" t = [] for x in string[:]: print t.append("A") #i don't want to append A, the final result is EAEA4A7A2ABA As it, it prints "None" 6 times. Then t is ['A','A','A','A','A'] What you have to do is to read about basic python. Search for python tutorial on the net.

Re: alphanumeric list

2011-03-16 Thread yqyq22
On Mar 15, 2:15 pm, yqyq22 wrote: > On Mar 15, 11:02 am, Laurent Claessens wrote: > > > > > > > Le 15/03/2011 09:10, yqyq22 a crit : > > > > Hi all, > > > I would like to put an alphanumeric string like this one > > > EE472A86441AF2E629DE360 in a list, then iterate inside the entire > > > string

Re: alphanumeric list

2011-03-15 Thread yqyq22
On Mar 15, 11:02 am, Laurent Claessens wrote: > Le 15/03/2011 09:10, yqyq22 a crit : > > > Hi all, > > I would like to put an alphanumeric string like this one > > EE472A86441AF2E629DE360 in a list, then iterate inside the entire > > string lenght and change each digit with a random digit. > > Do

Re: alphanumeric list

2011-03-15 Thread Ulrich Eckhardt
yqyq22 wrote: > Hi, to be honest i'm a newbye so i don't know where to start, i began > in this way but i don't know how to proceeed. > list = (EE472A86441AF2E629DE360) "list" is a builtin type, so you shouldn't use it as name for other things. The thing on the right-hand side of the assignment is

Re: alphanumeric list

2011-03-15 Thread Laurent Claessens
Le 15/03/2011 09:10, yqyq22 a écrit : Hi all, I would like to put an alphanumeric string like this one EE472A86441AF2E629DE360 in a list, then iterate inside the entire string lenght and change each digit with a random digit. Do u have some suggestion? thanks a lot This can be a way to begin :

Re: alphanumeric list

2011-03-15 Thread Ben Finney
yqyq22 writes: > On Mar 15, 9:20 am, Chris Rebert wrote: > > Can you show us your attempt? > > Hi, to be honest i'm a newbye so i don't know where to start Work through the entire Python tutorial, in sequence http://docs.python.org/tutorial/>. Not merely read: work through it, reading the expla

Re: alphanumeric list

2011-03-15 Thread Ulrich Eckhardt
yqyq22 wrote: > I would like to put an alphanumeric string like this one > EE472A86441AF2E629DE360 in a list, then iterate inside the entire > string lenght and change each digit with a random digit. What does "change each digit with a random digit"? Do you want to swap two random elements of the

Re: alphanumeric list

2011-03-15 Thread yqyq22
On Mar 15, 9:20 am, Chris Rebert wrote: > On Tue, Mar 15, 2011 at 1:10 AM, yqyq22 wrote: > > Hi all, > > I would like to put an alphanumeric string like this one > > EE472A86441AF2E629DE360 in a list, then iterate inside the entire > > string lenght and change each digit with a random digit. > >

Re: alphanumeric list

2011-03-15 Thread Chris Rebert
On Tue, Mar 15, 2011 at 1:10 AM, yqyq22 wrote: > Hi all, > I would like to put an alphanumeric string like this one > EE472A86441AF2E629DE360 in a list, then iterate inside the entire > string lenght and change each digit with a random digit. > Do u have some suggestion? thanks a lot Can you show

alphanumeric list

2011-03-15 Thread yqyq22
Hi all, I would like to put an alphanumeric string like this one EE472A86441AF2E629DE360 in a list, then iterate inside the entire string lenght and change each digit with a random digit. Do u have some suggestion? thanks a lot -- http://mail.python.org/mailman/listinfo/python-list