python - How can I randomly select an item from a list?

preview_player
Показать описание
#short
#python
#list
#random
How do I retrieve an item at random from the following list?
foo = ['a', 'b', 'c', 'd', 'e']
Рекомендации по теме
Комментарии
Автор

how about retrieving multiple items from the list

dominicezirike