exercise:6025b7e7de: Difference between revisions

From Stochiki
(Created page with "<div class="d-none"><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></div> In Las Vegas, a roulette wheel has 38 slots numbered 0, 00, 1, 2, \dots, 36. The 0 and 00 slots are green and half of the remaining 36 slots are red and half are black. A croupier spins the wheel and throws in an ivory ball. If you bet 1 dollar...")
 
No edit summary
 
Line 1: Line 1:
<div class="d-none"><math>
In Las Vegas, a roulette wheel has 38 slots numbered 0, 00, 1, 2, ..., 36.  The 0 and 00 slots are green and half of the remaining 36 slots are red and half are black.  A croupier spins the wheel and throws in an ivory ball.  If you bet 1 dollar on red, you win 1 dollar if the ball stops in a red slot and otherwise you lose 1 dollar.  Write a program to find the total winnings for a player who makes 1000 bets on red.
\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></div> In Las Vegas, a roulette wheel has 38 slots
numbered 0, 00, 1, 2, \dots, 36.  The 0 and 00 slots are green and half of
the
remaining 36 slots are red and half are black.  A croupier spins the wheel
and
throws in an ivory ball.  If you bet 1 dollar on red, you win 1 dollar if the
ball stops in a red slot and otherwise you lose 1 dollar.  Write a program to
find the total winnings for a player who makes 1000 bets on red.

Latest revision as of 20:10, 12 June 2024

In Las Vegas, a roulette wheel has 38 slots numbered 0, 00, 1, 2, ..., 36. The 0 and 00 slots are green and half of the remaining 36 slots are red and half are black. A croupier spins the wheel and throws in an ivory ball. If you bet 1 dollar on red, you win 1 dollar if the ball stops in a red slot and otherwise you lose 1 dollar. Write a program to find the total winnings for a player who makes 1000 bets on red.