Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

CGT 215 Lab 9 Arrays and Cellular Automata Learning objectives: Learn how to use arrays and pass them as function arguments. 0 Practice functions. 0

image text in transcribed
CGT 215 Lab 9 Arrays and Cellular Automata Learning objectives: Learn how to use arrays and pass them as function arguments. 0 Practice functions. 0 Learn about cellular automata. Description: Implement an algorithm for updating a row of shapes according to certain rules. Your program is a simple console application (do not use the cgt215Template). The program will produce a console output with interesting patterns by using the coat function. You can include logic to select which rules apply and hence produce different graphical outputs. Outline: A cellular automaton includes Boolean values (states) and a set of rules. The set of states is rewritten in each generation according to the rules. The Mathworld link below offers a good explanation of cellular automata. hm;:l/mathworld.wolfram.comelemenmCellularAutomatonhtml You will create a very simple cellular automaton: the Elementary cellular automata. You can represent the automaton as an array of bools of size 79. In each generation you will rewrite the array into another array by using the rule 126 (see the Mathworld link) or any other rules of your choice. The output is a list of stars into the console window (see the image below). Think of each row output to the console window as your array of bools. Every time we apply the rules, the array changes and we output it again. You MUST create and use some functions for this lab in order to receive full credit

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Financial management theory and practice

Authors: Eugene F. Brigham and Michael C. Ehrhardt

12th Edition

978-0030243998, 30243998, 324422695, 978-0324422696

Students also viewed these Programming questions

Question

WHAT IS ACCOUNTING AND FUNCTIONS?

Answered: 1 week ago

Question

Breathing explain?

Answered: 1 week ago

Question

WHAT IS DOUBLE ENTRY ACCOUNTING SYSTEM?

Answered: 1 week ago