Question: /*IN JAVA --Write a program that determines the probability of tossing a coin 100 times and getting exactly 0, 1, 2, 3, etc. heads. This

/*IN JAVA --Write a program that determines the probability of tossing a coin 100 times and getting exactly 0, 1, 2, 3, etc. heads. This is the binomial probability distribution. Store the probability in an array. You could get 0 heads or 100 heads or anything in between. The probability of a success is .5, and also the probability of a failure is .5. Print out in table form, column 1=r; goes 0 to 100, and then column 2, the probability of r. Use 4 decimal places for the probability. You know if you get the correct answers because The sum of all the probabilities is 1.0, and all probabilities are in the range of 0 to 1 inclusive.

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!