Assume I have the following list:
foo = [\'a\', \'b\', \'c\', \'d\', \'e\']
What is the simplest way to retrieve an item at random from thi
This may already be an answer but you could use random.shuffle. Example:
random.shuffle
import random foo = ['a', 'b', 'c', 'd', 'e'] random.shuffle(foo)