| | |
List operation problem
Thread Solved
![]() |
Yes there is it's pretty simple too
Hope that helps.
Chris
python Syntax (Toggle Plain Text)
mylist = ['blue', 'red', 'green', 'green', 'red', 'red'] for word in set(mylist): print word, "appears", mylist.count(word), "times."
Hope that helps.
Chris
Knowledge is power -- But experience is everything
![]() |
Similar Threads
- Amaena and Microsoft problem (Viruses, Spyware and other Nasties)
- Some Data Structure Problem (C++)
- BIG problem with STL List Container (C)
- Problem on array based list (C)
- Swing Problem (Java)
- Singly-Linked Lists problem (C++)
Other Threads in the Python Forum
- Previous Thread: Translate C/C++ Code to python
- Next Thread: wxTreeCtrl - Load Tree structure from file
| Thread Tools | Search this Thread |
abrupt accessdenied ansi anti apache application approximation argv array assignment backend beginner binary bluetooth builtin calculator change character converter countpasswordentry curved customdialog dan08 dictionary edit exe file float format function gnu heads homework ideas inches input java keyboard lapse leftmouse library line lines linux list lists loop microphone mouse movingimageswithpygame mysqlquery newb number numbers numeric output parameters parsing path phonebook pointer prime programming py2exe pygame pyopengl python random recursion redirect remote reverse scrolledtext session software sprite sqlite statictext statistics string strings syntax terminal text thread threading time tlapse tuple twoup ubuntu unicode unit urllib urllib2 variable wordgame write wxpython xlib





