Coin tossing write a program that simulates coin tossing


Question: (Coin Tossing) Write a program that simulates coin tossing. For each toss of the coin the program should print Heads or Tails. Let the program toss the coin 100 times, and count the number of times each side of the coin appears. Print the results. The program should call a separate function flip that takes no arguments and returns 0 for tails and 1 for heads.

Solution Preview :

Prepared by a verified Expert
Basic Computer Science: Coin tossing write a program that simulates coin tossing
Reference No:- TGS02403980

Now Priced at $15 (50% Discount)

Recommended (98%)

Rated (4.3/5)