Question: C PROGRAMMING Make a lottery line inspection program. The program first asks the user how many lines to process in the program (max 5). The
C PROGRAMMING
Make a lottery line inspection program. The program first asks the user how many lines to process in the program (max 5). The program then reads the number of lottery lines (number at a time) entered from the user manually and draws the remaining lines (up to a maximum of five lines) on behalf of the user with random numbers (naturally between 1-40). Finally, the program draws the correct lottery numbers and notifies the user how he or she did on each grid. The program prints the user's grids and the correct lottery line and information on how many numbers and additional numbers there were in each line. Example run: How many lines do you want to enter (max. 5 lines)> 2 Enter the number 1 in line 1> # Enter the number 2 in line 1> # Enter the number 3 in line 1> # Enter the 4th number on line 1> # Enter the 5th number in line 1> # Enter the 6th number on line 1> # Enter the number 7 in line 1> # Enter the number 1 in line 2> ## Enter the number 2 in line 2> ## Enter the number 3 in line 2> ## Enter the 4th number in line 2> ## Enter the 5th number in line 2> ## Enter the number 6 in line 2> ## Enter the 7th number in line 2> # Lottery lines: # # # # # # # # ## ## ## ## ## ## # # # # ## ## ## # ## ## ## ## ## ## ## ## ## ## ## ## ## Right line: # # ## ## ## ## ## additional numbers: # ## ## Line 1 contains # correct and # additional numbers Line 2 contains # correct and # additional numbers Line 3 has # correct and # additional numbers Line 4 has # correct and # additional numbers Line 5 has # correct and # additional numbers
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
