Files
game_theory_of_life/game_theory_of_life.py
Luis Rodrigues 1ca8aa3c8b criação de pasta 'modules'
pasta 'modules' contém os diferentes módulos usados pela app
2024-09-07 00:57:36 +01:00

20 lines
448 B
Python

from modules.agente import Agente
tamanho_mundo: tuple = (24, 24)
mundo: list = []
# inicializar mundo
for _ in range(0, tamanho_mundo[0]):
mundo_tmp: list = []
for _ in range(0, tamanho_mundo[1]):
mundo_tmp.append(Agente())
mundo.append(mundo_tmp)
# preencher mundo
m, n = 0, 0
for m in range(0, tamanho_mundo[0]):
for n in range(0, tamanho_mundo[1]):
print(f'{mundo[m][n].pontuacao:2} ', end='')
print('')