sup = ['eyes', 'nose', 'mouth']
car = ['4wd', 'hatch', 'coupe']
tan = ['dark', 'light', 'pale']
objects = ['sup', 'car', 'tan']
import random
print 'choose 2 objects from the following list separated by commas:'
print 'sup, car, tan'
chorol []
chorol.extend (objects[:2])
from random import choice
print choice (1)
from random import choice
print choice (2)
我试图让用户从一组 3 个列表中选择 2 个列表,然后从用户选择的 2 个列表中的每个列表中打印 1 个随机项目。我最近才开始学习编码,所以这个错误可能是非常基本的。