Question: Write a FORTRAN subroutine named count which receives an integer array, where the values are between 1 and 9 (both included), and array size and
- Write a FORTRAN subroutine named count which receives an integer array, where the values are between 1 and 9 (both included), and array size and twice of this size to be used as the size of the new array. The subroutine should find and return the values from 1 to 9 and the number of times they are repeated in another array.
Example:
If a=(3,6,6,1,1,7,3,1) then count(a, 8, b, 16) will return an array which is: (1,3,2,0,3,2,4,0,5,0,6,2,7,1,8,0,9,0)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
