From 7c86e83f65386dd6095bf7aee5c2173011a0e997 Mon Sep 17 00:00:00 2001 From: thewellnesscurator Date: Sun, 3 Nov 2024 15:46:32 -0500 Subject: [PATCH] file updated to include Annie's code for fizzbuzz exercise. --- fizzbuzz.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/fizzbuzz.py b/fizzbuzz.py index 218f7aa..e0a33bb 100644 --- a/fizzbuzz.py +++ b/fizzbuzz.py @@ -1,2 +1,10 @@ -# add your code here +for num in range(1,101): + if num % 3 == 0 and num % 5 == 0: + print("FizzBuzz") + elif num % 3 == 0: + print("Fizz") + elif num % 5 == 0: + print("Buzz") + else: + print(num)