[Tutor] List issues
wheelerg at seattleu.edu
Thu Apr 17 03:10:20 CEST 2014
Im having trouble completing this function with lists. Im supposed to create a function that will let me know if there are repeating elements so I wrote this and am not sure where the error lies. It is supposed to count the number of times a number appears and if its greater than 1 then it will say True.
list = [1,2,2,2,3,4]
for i in range(len[list]):
if list.count(i) > 1:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Tutor