Question: CIS-210 Introduction to C++ Programming (Fall 2017) Assignment-5 Points: 100 Due Date: 4/26/2017 (beginning of class) 1. A magic square is a two-dimensional array of

 CIS-210 Introduction to C++ Programming (Fall 2017) Assignment-5 Points: 100 Due

Date: 4/26/2017 (beginning of class) 1. A magic square is a two-dimensional

array of positive integers, which have the following characteristics The number of

rows equals the number of columns All entries must be positive integers

CIS-210 Introduction to C++ Programming (Fall 2017) Assignment-5 Points: 100 Due Date: 4/26/2017 (beginning of class) 1. A magic square is a two-dimensional array of positive integers, which have the following characteristics The number of rows equals the number of columns All entries must be positive integers The sum of all entries in each row, each column and the two diagonals are write a C++ program to determine if a set of numbers represents a magic4x4 Square. Read a set of numbers from the keyboard (see sample input below) Validate the input to ensure integer numbers are positive. If a negative number is given, generate an error message and prompt the user to reenter a number Your program must include the following functions: o main-display welcome message, declare array, call user defined functions getlnput, checksums, checkRowSums, checkColSums, checkDiagSums, and a splayResult o getlnput prompts uur for and validates the input (see sample input below) o checkSums computes an initial sum and then calls the functions checkRowSums, checkCoISums, and checkDiagsums. The functions checkRowSums, checkColSums, and checkDiagsums should return a Boolean value that indicates ifthe corresponding sums represent a magic Square Note: the check R check Col and checkDiagSums functions should only be called if necessary o display Result -displays the results (see sample output below)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!