8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d73b863 commit 0881715Copy full SHA for 0881715
ch08-conditional-logic/9b-challenge-simulate-an-election.py
@@ -55,5 +55,5 @@ def run_election(regional_chances):
55
# Display the probabilities that candidate A or candidate B wins the
56
# election. Note the probability that B wins can be calculated by
57
# subtracting the probability that A wins from 1.
58
-print(f"Probability A wins: {num_times_A_wins / num_trials}")
59
-print(f"Probability B wins: {1 - (num_times_A_wins / num_trials)}")
+print(f"Probability A wins: {num_times_A_wins / NUM_TRIALS}")
+print(f"Probability B wins: {1 - (num_times_A_wins / NUM_TRIALS)}")
0 commit comments