Question: C++ program using functions only, NOT arrays! The format should be the same, note: after each line besides the last line there's a space. Your

 C++ program using functions only, NOT arrays! The format should be

C++ program using functions only, NOT arrays! The format should be the same, note: after each line besides the last line there's a space.

Your professor has asked several different pattern questions. And, he has many others waiting for you) He wants you to draw a pattern as described below: First you put 4 numbers to the corners of the square, Then you write 4 other numbers next to each corner until finish outer layer of the square. After you finish this layer, you go to the inner layer and you repeat. Question: Write a program that gets the size of the pattern and draws the pattern described above Input specification You will be given just one integer number (n) where n is between 1 and 60. Otherwise, "Wrong input" is printed Output specification Show n2 integer numbers (separated by spaces) as described above Input 1 4 Output 1 1592 12 13 14 816 15 10 Input 1 5 Output 1 159 132 6 17 21 18 6 2 24 25 22 10 8 20 23 19 14 415 1173

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!