Random Cannon Generator

Dec 3, 2014 at 9:09pm
I am in a computer science class this semester and for an assignment i have to create a program that will:

randomly generate 2 cannon angles between 0 and 90 degrees.
randomly generate 2 velocities for the objects being shot from the cannon.
say which one goes farther.
give a point if they guess right, take a point if they guess wrong.
and tell how many rounds they played, how many right and wrong guesses.

unfortunately i was absent the class where my teacher discussed the rand(), stand(), and RAND_MAX() functions. so if anyone is willing to help me out with this program id really appreciate it
Dec 3, 2014 at 10:19pm
check out the reference section of this site or just search rand()
Topic archived. No new replies allowed.