Py学习  »  Makonede  »  全部回复
回复总数  1

更简单的方法:

for row in picture:
    for col in row:
        print(end=' *'[col])
    print()

非常简短的版本:

'\n'.join(''.join(map(' *'.__getitem__, row)) for row in picture)