LeetCode #412 - FizzBuzz in Python (Multiple Solutions, Explanations and Complexity Analysis)

preview_player
Показать описание
Solving LeetCode problem #412 FizzBuzz in Python with multiple solutions, explanations, and Big (O) complexity analysis. Enjoy!
Рекомендации по теме
Комментарии
Автор

Excellent video bro. This helps me a lot. Keep it up. You deserve way more subs.

mwsentertainment
Автор

i did it in python took decades
import math
import sys

def fizzBuzz(n):
line=sys.stdin.readline()
while line:
line
p=int(15)
if line==p:
print(line)
else:
print(line, "pop")

line=n
for i in range(1, line+1):
if i % 3==0 and i % 5 ==0:
print("FizzBuzz")
elif i % 3==0:
print("Fizz")
elif i % 5 ==0:
print("Buzz")
else:
print(i)

taresypp
Автор

Michael is there anyway i can text you private.

andreas_dk