Question: What is the program solution in C++'s Visual Studio Code System that will help me pass this Object-Oriented Programming Assignment? Lights Out Class Create a
What is the program solution in C++'s Visual Studio Code System that will help me pass this Object-Oriented Programming Assignment?

Lights Out Class Create a C++ class to represent a game of Lights Out. Specifically, your class should provide the following public interface: LightsOut()a constructor that sets all lights "off" void on(int row, int col) set a specific light "on" (used to setup the game) bool get(int row, int col) get a specific light value (used to show the game) void toggle(int row, int col) toggle a light and its neighbors, per the game rules bool success() check if the player is successful (all lights are out) 1 s row 5,1 5 col s 5 for all member functions To get a feel for the game, play a live version of the game here. You could even try to reverse engineer the Javascript code, but I expect that would be much, MUCH harder than just working it out on your own. There are several ways to model the private information required by the state of the game: use a 2-dimensional array of boolean values use a 2-dimensional array of character values use a 2-dimensional array of integer values use a 1-dimensional array of string values use a long 1-dimensional array of boolean values, with custom row/column indexing use a long 1-dimensional array of integer values, with custom row/column indexing use a 1-dimensional array of integer values, with bits representing individual "lights" in a row use a 1-dimensional array of integer values, with bits representing individual "lights" in a column use a single integer with bits representing each "light" via custom bit "indexing" some other idea Regardless of which of these you decide to you use, you will need to determine exactly how the input values (1..5) will map to the elements of your array or the characters of your string or bits your integer. Different choices make different parts of the problem easier and other parts harder; this is not unusual in software development. You should practice converting your code between alternative solutions, so you will become both accomplished and comfortable with this sort of transformation. Lights Out Class Create a C++ class to represent a game of Lights Out. Specifically, your class should provide the following public interface: LightsOut()a constructor that sets all lights "off" void on(int row, int col) set a specific light "on" (used to setup the game) bool get(int row, int col) get a specific light value (used to show the game) void toggle(int row, int col) toggle a light and its neighbors, per the game rules bool success() check if the player is successful (all lights are out) 1 s row 5,1 5 col s 5 for all member functions To get a feel for the game, play a live version of the game here. You could even try to reverse engineer the Javascript code, but I expect that would be much, MUCH harder than just working it out on your own. There are several ways to model the private information required by the state of the game: use a 2-dimensional array of boolean values use a 2-dimensional array of character values use a 2-dimensional array of integer values use a 1-dimensional array of string values use a long 1-dimensional array of boolean values, with custom row/column indexing use a long 1-dimensional array of integer values, with custom row/column indexing use a 1-dimensional array of integer values, with bits representing individual "lights" in a row use a 1-dimensional array of integer values, with bits representing individual "lights" in a column use a single integer with bits representing each "light" via custom bit "indexing" some other idea Regardless of which of these you decide to you use, you will need to determine exactly how the input values (1..5) will map to the elements of your array or the characters of your string or bits your integer. Different choices make different parts of the problem easier and other parts harder; this is not unusual in software development. You should practice converting your code between alternative solutions, so you will become both accomplished and comfortable with this sort of transformation
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
