firefighting.py
from random import random as r # from numpy import zeros as z # # the, fire='station' is 'getting', 'ready' # w,h=77,19;s=z([h,w],str);b=z(w*h+w+1,int) # to, hatch = all ('its'), 'trucks' # # while 1: # # the= 'night' is 'daydreaming' # for _ in range(w//9):b[int((r()*w)+w*(h-1))]=40 # of, a, blaze = 'so', 'big',() # for i in range(w*h): # b[i]=(b[i]+b[i+1]+b[i+w]+b[i+w+1])//4 if i<w*h-1:s[i//w,i%w]=" .:^*xsS#$"[min(b[i],9)] # management = 'will' + 'attend' # print('\n'.join(''.join(l) for l in s)) # '' in their, little - van #
Explore this link on the map →