我的目标是以无序方式存储来自用户的许多输入。所以,我决定使用set. 我到目前为止的代码是:
set
a = input() b = input() c = input() d = input() all = a, b, c, d print(set(all))
但是,我不想像input()上面那样重复几次。有没有办法实现这一目标?
input()
python input set python-3.x
input ×1
python ×1
python-3.x ×1
set ×1