I have to write a program that allows a user to pick five numbers from one to 55. The computer will then generate 5 random numbers and determine how many of the users choices match the generated numbers. I have to create an algorithm for this program. The program will have a void function to generate 5 random numbers from one to 55, no duplicate numbers allowed. The random numbers and the choices will be stored in two one dimensional arrays. The program will have a void function to display the random
numbers and the users choices and the number of matches. The program will contain a loop that will generate a new set of random numbers and user choices unless the user tells the program to quit. I don't even know where to start with this. The void function is what I'm not getting mostly.
Recommended Answers
Jump to PostI put together this to show you the void function part and I included how to make the 5 random numbers.
Things you need to do:
-User input for 5 numbers (check each to see if they are within 1-55)
-Make a checker for what numbers the user got …
All 4 Replies
sfuo
111
Practically a Master Poster
Clinton Portis
211
Practically a Posting Shark
vinochick
0
Newbie Poster
pecet
1
Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.