Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Project [5l: Arrays Due Thursday, 3/15/2018, 11:59am Project Goals The goals of this project are to: . Get students familiar with the usage of 1D
Project [5l: Arrays Due Thursday, 3/15/2018, 11:59am Project Goals The goals of this project are to: . Get students familiar with the usage of 1D arrays 2. Get students familiar with the usage of 2D arrays Important Notes: . Formatting: Make sure that you follow the precise recommendations for the output content and formatting: for example do not change the text in the first problem from "Enter the size of the array: " to "Enter array size: ". Your assignment will auto-graded and any changes in formatting will result in a loss in the grade Comments: Header comments are required on all files and recommended for the rest of the program. Points will be deducted if no header comments are included. Restriction: The use of goto statements anywhere within this program is prohibited. Points will be deducted if goto is used 2. 3. Problem 1 Write a program that asks the user to enter an NxM dimensional array containing single digit values (only the digits between 0 and 9) and counts the number of times each one of the 10 digits appears in the array. This program should: Prompt the user to enter the sizes (number of rows and number of columns) of the array, and read in the dimensions given by the user Prompt the user to enter the array row-by-row and read in each value (separated by spaces) Display the total number of times each digit appears in the array Display the 1D array containing the counts of each digit in one line Display the 2D array that the user entered . The program should function as follows (items underlined are to be entered by the user) This program counts occurrences of digits0 through 9 in an NxM array. Enter the size of the array (Row Column): 2 6 Enter row 0:01 2 3 45 Enter row 1:01 6 78 9 Total counts for each digit: Digit 0 occurs 2 times Digit 1 occurs 2 times
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started