Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Can you edit my C++ code? (In the below) Hello, I am making a game that has 2 players. Each player replace 4x7 columns of

Can you edit my C++ code? (In the below)

Hello, I am making a game that has 2 players. Each player replace 4x7 columns of 0's with either 1 or 2 respectively. I believe there is a problem with my code, because there are 4 columns and 7 rows, but if I enter numbers bigger than these, it still accepts. Can you please fix that. Also I want you to print the final version of that 4x7 board after each player makes their move, so the next player can understand which positions are filled.

I am giving you an example image:

image text in transcribed

The code I made:

#include  using namespace std; // function to print the board void printarray(int arr[][4]){ for (int i = 0; i   Oyuncul dizi seciniz (0-3): 3 Oyuncul konum seciniz (0-6): 3 Oyuncul yerlestirilecek elemani seciniz (1-2):1 | 00 00 1 2 101 0 1 101 LOT 101 1001 1 1 1 101 | 2010 01 1 21 1 1 1 10 11 I TOI2 2 | ***************** 0 1 2 3

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_2

Step: 3

blur-text-image_3

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

Online Systems For Physicians And Medical Professionals How To Use And Access Databases

Authors: Harley Bjelland

1st Edition

1878487442, 9781878487445

More Books

Students also viewed these Databases questions

Question

=+ (d) Show that Y ,, Y2, ... are independent.

Answered: 1 week ago