例如,有没有办法轻松地将列表中的数字转换为个位数
population = ['10001','11111','11010','110001']
into ['1','0','0','0','1']
add each digit in each set and put it in another list like
this
evaluation = [2,5,3,3] (adding up all the 1's up on the first list)
我对 Python 很陌生,所以我不确定我是否正确地做这件事
SMILET
慕尼黑8549860
收到一只叮咚
相关分类