Write a program named GuessingGame that generates a random number in the range of 1 through 100 and asks the user to guess what the number is. If the user's guess is higher than the random number, the program should display "Too high, try again." If the user's guess is lower than the random number, the program should display "Too low, try again." If the user guesses the correct number, the application should congratulate the user and then generate a new random number so the game can start over. Keep a count of the number of guesses that the user makes. When the user correctly guesses the random number, the program should display the number of guesses it took. When the user wins the game, ask if he/she wants to play again. If the answer is yes, then generate a new random number and start over.

For this program, create the following functions:
ĽA function to generate and return a random number in the range of 1 through 100.
ĽA function that asks the user for a guess and returns the value.
ĽA function that evaluates the user's guess and returns a message indicating whether it is too high, too low, or a match.

Your program should have a game loop that continues as long as the user wants to keep playing. Within this outer loop will be an inner loop responsible to keep asking the user for guesses until the user gets the number right. In these loops call the appropriate functions you've created as needed.

I have tried to do this program and i like to think that ive gotten pretty far i just cant figure out the right order or loop or something help me...here is my code: