"Dave Angel" <da...@ieee.org> wrote
while teller < len(u):
getal1 = u[teller] + v[teller]
uitkomst = uitkomst + str(getal1)
But then I get a list of string instead of integers.
You're close. Now that you've initialized the result variable to
[], you can use + just as you're doing. Just take out the str()
function in that line. You've still got duplicate names there
between that function and the outer level code.
You will need to make the new result a list too for + to work, like
so:
uitkomst = uitkomst + [getal1]
Or you can just append() the answer to uitkomst
HTH,
--
Alan Gauld
Author of the Learn to Program web site
http://www.alan-g.me.uk/
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor