RosettaCodeData/Task/Sleeping-Beauty-problem/EasyLang/sleeping-beauty-problem.easy
2026-04-30 12:34:36 -04:00

11 lines
199 B
Text

reps = 1e6
for i to reps
coin = random 1 2
wakings += 1
if coin = 1
heads += 1
else
wakings += 1
.
.
print "Chance of waking up with heads: " & heads / wakings * 100 & "%"