Coin-Toss Simulator
Write a class named Coin . The Coin class should have the following field:
Write a program that demonstrates the Coin class. The program should create an instance of the class and display the side that is initially facing up. Then, use a loop to toss the coin 20 times. Each time the coin is tossed, display the side that is facing up. The program should keep count of the number of times a head is facing up and the number of times a tail is facing up and display those values after the loop finishes.
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.