From 11fb8f778fab60218f33071068c3cc1141051d7b Mon Sep 17 00:00:00 2001 From: LittleTealeaf Date: Tue, 11 Jan 2022 16:11:10 -0500 Subject: [PATCH] Added comments --- 75_Roulette/python/roulette.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/75_Roulette/python/roulette.py b/75_Roulette/python/roulette.py index cca991dd..c839adc7 100644 --- a/75_Roulette/python/roulette.py +++ b/75_Roulette/python/roulette.py @@ -56,6 +56,7 @@ THE MINIMUM BET IS $5, THE MAXIMUM IS $500. """) def query_bets(): + """Queries the user to input their bets""" betCount = -1 while betCount <= 0: try: @@ -87,6 +88,7 @@ def query_bets(): return bet_IDs,bet_Values def bet_results(bet_IDs,bet_Values,result): + """Computes the results, prints them, and returns the total net winnings""" total_winnings = 0 def get_modifier(id,num): if id == 37 and num <= 12: @@ -130,6 +132,7 @@ def bet_results(bet_IDs,bet_Values,result): return winnings def print_check(amount): + """Prints a check of a given amount""" name = input("TO WHOM SHALL I MAKE THE CHECK? ") print("-" * 72) @@ -203,7 +206,8 @@ def main(): def stringtobool(string): + """Converts a string to a bool""" return string.lower() in ("yes","y","true","t","yes") -# a,b = query_bets() -main() +if __name__ == '__main__': + main()