Program to implement the simulation of life

Assignment Help Basic Computer Science
Reference no: EM131237589

DO IN C++

Write a program to implement the simulation of life as described in Scientific American by Martin Gardner. The program will be implemented on a two dimensional surface of size 60 by 60 visible elements. The rules of the simulation are as follows:

1) An initial set of cells are marked as "alive" by the user. This is generation 0. Yourprogram will ask the user to input a set of row and column values to let the user
determine which cells are "alive". Display this generation.

2) Cells change for each succeeding generation by the following rules:

a. A living cell dies of overcrowding in the next generation if it currently has 4 or more living neighbors.

b. A living cell dies of loneliness in the next generation if it currently has only 0 or 1 living neighbors.

c. An empty cell becomes a "birth" cell (becomes alive) in the next generation if it has exactly 3 living neighbors.

d. All other cells remain unchanged.

3) The new generation becomes the current generation and is displayed.

4) After displaying each new generation, ask the user if they wish to continue to the next generation or stop at this point.

Reference no: EM131237589

Questions Cloud

What is the impact of this on the stock price : On May 31 a company's stock price is $70. One million shares are outstanding. An executive exercises 100,000 stock options with a strike price of $50. -  What is the impact of this on the stock price?
What is range of geologic periods for crinoid platycrinities : Table 24.2 shows, in color, the range in the rock record of six different fossils of the Paleozoic era. Along the top of the chart is a letter for each period of the era (C for Cambrian, P for Pennsylvanian, PR for Permian, and so on).
What is the result of the auction : In a Dutch auction of 10,000 options, bids are as given: - What is the result of the auction? - Who buys how many at what price?
What will the company report as an expense for the options : The company pays no dividends and the risk-free rate is 4%. What will the company report as an expense for the options on its income statement?
Program to implement the simulation of life : Write a program to implement the simulation of life as described in Scientific American by Martin Gardner. The program will be implemented on a two dimensional surface of size 60 by 60 visible elements. The rules of the simulation are as follows:
Develop an initial budget for your plan : Prepare a pie chart showing the dollars/percentages budgeted for each included marketing activity for the first year. Provide justification for your choices. Explain the evaluation and control methods you will use to measure the success of your plan.
What can be said about age of a rock that contains fossil : Suppose that one species of index fossil lived between 410 and 380 Mya and another lived between 440 and 350 Mya. What can be said about the age of a rock that contains fossils of both species?
The accounting treatment of stock options is crazy : We estimated the value of each option on the grant date to be $5. At our year-end the stock price had fallen to $4, but we were still stuck with a $50 million charge to the P&L.'' -  Discuss.
Netbeans integrated development environment : Write a Java application using NetBeans Integrated Development Environment (IDE) that calculates the total annual compensation of a salesperson. Consider the following factors:

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Versions microsoft word

By now, all of you have worked with a Word document, especially with Microsoft Word and its different versions. Please discuss your experience using Microsoft Word prior to taking this course, and explain any new features you have learned.

  Find the corresponding matrix of the digraph

Label and find the number of edges, degrees and vertex in the above digraph and find the corresponding matrix of the digraph above.

  Find the percent of adults in each province or territory

It makes no sense to find for these data and use it to get a confidence interval for the mean percent μ in all 13 provinces or territories. Why not?

  Explain the development of health insurance

In a two to three page paper, explain the development of health insurance in the United States. Include a brief discussion as to the current state of both traditional health insurance and managed care. Is traditional health insurance still a viabl..

  Implement a class for complete binary trees

You should have only one member function that adds a new node(since there is only one place where a node may be added, and one member function that removes the last node of the tree.

  What features of the product could serve as design variables

Conceive a modern real life product ( e.g. , smartphone, solar PV, or PHEV) where optimization can be used to further improve its design. Describe the scope of applying optimization in that context. Specifically state (i) what objectives will need to..

  Does company culture impact security

Does company culture impact security? If so, in what way? How does this fit into computer ethics?

  Identify hardware and software needed to secure

Identify hardware and software needed to secure

  Write an output statement that displays the memory location

Write an output statement that displays the memory location of the value 4 stored in intArray[] in base-16 integer format.

  Why should there be a detailed implementation/upgrade plan

In regards to technology? Why should there be a detailed implementation/upgrade plan? Who should be involved in making this plan?

  Family-owned and operated business

NASCAR is an acronym for what family-owned and operated business?

  Write a program that reads in an integer value

Write a program that reads in an integer value for n and then sums the integers from n to 2*n if n is nonnegative, or from 2*n to n if n is negative. Write the code in two versions: one using only for loops and the other using only while loops.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd