Question: Write a MAIN function and a FUNCTION to compute and print the elements of a two - dimensional 3 0 X 2 0 integer array
Write a MAIN function and a FUNCTION to compute and print the elements of a twodimensional X integer array A which are square numbers. A Within the MAIN function: Declare a twodimensional X integer array A and initialize it with random numbers between and inclusive. Declare also an onedimensional integer array B with a reasonable size to hold the elements of the array A which are square numbers. Pass the arrays A and B to the FUNCTION as arguments and get the return value the size of B the number of square elements of A stored in B from the FUNCTION. Print the array B without duplicates ie repeated elements will be written only once. B Within the FUNCTION: Read array A elements and compute and store the square elements of A into the array B Return the size of the array B the number of the square elements stored in B to the MAIN function. c
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
