Question: IN PROGRAM C : Use the rand() function to flip a coin by attributing an odd number to heads and an even number to tails.

IN PROGRAM C:

Use the rand() function to flip a coin by attributing an odd number to "heads" and an even number to "tails". Write a complete C program that flips a coin N times, where N is input from the keyboard. Count how many heads and tails you get, and output the results as percentages. For example, heres one possible output:

IN PROGRAM C: Use the rand() function to flip a coin by

Heads: Tails: 47.2% 52.8%

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!