반응형
python coin flips #파이썬 동전 던지기 #파이썬 알고리즘 문제
-
[알고리즘 스터디] python coin flips 문제 풀기5) etc. 2022. 6. 16. 15:47
문제 Create a program that uses Python’s random number generator to simulate flipping a coin several times. The simulated coin should be fair, meaning that the probability of heads is equal to the probability of tails. Your program should flip simulated coins until either 3 consecutive heads of 3 consecutive tails occur. Display an H each time the outcome is heads, and a T each time the outcome is t..