Skip to content

victor-giro-galceran/Game-Of-Life

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 

Repository files navigation

Game Of Life

The Game of Life is an example of a cellular automaton and a zero-player game. It takes place on an infinite two-dimensional grid in which cells can be ‘on’ (alive) or ‘off’ (dead), and is defined by a set of rules that jointly determine the state of a cell given the state of its neighbours.

Rules

✓ Every living cell with 2 or 3 neighboring cells "survives"

✓ Every cell with 4 or more neighbors dies from "overpopulation"

✓ Every cell with 1 or no neighbors dies from "loneliness"

✓ Each dead cell with 3 neighboring live cells, "revive"

My Conway's Game Of Life

My game of life is developed interactively by console, this way, you can see the progress of each generation.

Today's code To update
  • Works
  • Simple
  • Interactive
  • Needs some updates
  • Clear data after task
  • Automatic method
  • Not perfect
  • Not definitive
  • First I have created a menu to perform different processes.

    image

    If you choose to place the cells manually, you will be prompted to enter the row and column.

    image

    If you decide to have the cells placed automatically, you will be asked how many groups you want to generate.

    image

    Once the cells have been introduced, either manually or automatically, a total reproduction of generations will be required to contemplate their evolution.

    image

    Game-Of-Life

    Contributions, issues, and feature requests are welcome! Give a ⭐️ if you like this project!