Minesweeper by comfuture (2hrs)

a=271;import os;i=os.read(0,a);p=lambda p:0<=p<a and i[p]=='*';print ''.join([i[n]=='.' and str(sum([p(n+m) for m in [-1,1,-17,17,-18,-16,16,18]])) or i[n] for n in range(0,a)])

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return top