BBy Bot
Jun 09'24

Exercise

[math] \newcommand{\NA}{{\rm NA}} \newcommand{\mat}[1]{{\bf#1}} \newcommand{\exref}[1]{\ref{##1}} \newcommand{\secstoprocess}{\all} \newcommand{\NA}{{\rm NA}} \newcommand{\mathds}{\mathbb}[/math]

Write a program to toss a coin 10,00 times. Let [math]S_n[/math] be the

number of heads in the first [math]n[/math] tosses. Have your program print out, after every 1000 tosses, [math]S_n - n/2[/math]. On the basis of this simulation, is it correct to say that you can expect heads about half of the time when you toss a coin a large number of times?