Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

ConwaysGameOfLifeInGroovy

An implementation of Conway's Game of Life in Groovy. This code illustrates some of the cool features in the Groovy language.

Running the script

groovy GameOfLifeScript

Sample output

Generation 1
********************************************************************************
.....
..X..
..X..
..X..
.....

Generation 2
********************************************************************************
.....
.....
.XXX.
.....
.....

Generation 3
********************************************************************************
.....
..X..
..X..
..X..
.....

Generation 4
********************************************************************************
.....
.....
.XXX.
.....
.....

Generation 5
********************************************************************************
.....
..X..
..X..
..X..
.....

Generation 1
********************************************************************************
..........
..X.......
...X......
.XXX......
..........
..........
..........
..........
..........
..........

Generation 2
********************************************************************************
..........
..........
.X.X......
..XX......
..X.......
..........
..........
..........
..........
..........

Generation 3
********************************************************************************
..........
..........
...X......
.X.X......
..XX......
..........
..........
..........
..........
..........

Generation 4
********************************************************************************
..........
..........
..X.......
...XX.....
..XX......
..........
..........
..........
..........
..........

Generation 5
********************************************************************************
..........
..........
...X......
....X.....
..XXX.....
..........
..........
..........
..........
..........

Generation 6
********************************************************************************
..........
..........
..........
..X.X.....
...XX.....
...X......
..........
..........
..........
..........

Generation 7
********************************************************************************
..........
..........
..........
....X.....
..X.X.....
...XX.....
..........
..........
..........
..........

Generation 8
********************************************************************************
..........
..........
..........
...X......
....XX....
...XX.....
..........
..........
..........
..........

Generation 9
********************************************************************************
..........
..........
..........
....X.....
.....X....
...XXX....
..........
..........
..........
..........

Generation 10
********************************************************************************
..........
..........
..........
..........
...X.X....
....XX....
....X.....
..........
..........
..........

About

An implementation of Conway's Game of Life in Groovy

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages