[Solved] “FizzBuzz”-style program that checks for divisibility by multiple numbers prints numbers multiple times when it should print words
[ad_1] Add the “Fizz” “Buzz” “Bizz” if the division is possible, at the end if nothing has been added, it means that you have to print the number itself. n = 0 toTest = [ 3, 5, 7 ] outputCanBe = [ “Fizz”, “Buzz”, “Bizz” ] outputIndex = 0 iteration = (len(toTest)) while n <= … Read more