C101 Laboratory Session #10 solved


Category: You will receive a download link of the .ZIP file upon Payment


5/5 - (1 vote)

Lab Goals 1) Dealing with random numbers.
2) More practice with functions.
Write a program that has user pick an integer, either 1, 2 or 3, the computer then picks a
random number with this same range. Both numbers are passed into a function and if
they are both the same the function will display this information, else the function will
display they are not the same. Program should then prompt the user to play again and
repeat until the user decides to quit. A new random number is picked along with the new
users choice each time. Make sure to use srand(time(NULL)); which only needs to be
called one time and not inside any loop.