Python Programming Tutorial - 11 - Continue

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

You'll never bit Russia in hockey, we're unstoppable!
Btw, your tutorials are awesome, thank you so much. I never worked with python before, but you make it look so easy, so it all feels like I already know everything)

dallonavery
Автор

I enjoy how these videos relate to hockey. Which is...really, not at all. But he keeps mentioning it, so that's good enough.

personMN
Автор

I think its good to have homeworks after each episode. It helps us apply the things we learned from the video.

TheLiryc
Автор

its kind of sad how the views just get less and less...

vincentliu
Автор

numbersTaken = [2, 5, 15, 12, 19]

print("Here are the remaining numbers:")

for n in range(1, 20):
if n in numbersTaken:
continue
print(n, sep='', end=', ')

damienbertrand
Автор

A mistake I made was I used "is numbers taken" rather than "in". Just a heads up for other noobies giving this a go who can't figure out why it isn't working

AnusInTheMist
Автор

"lets change this to thiry" *Changes to thirteen*

acensti
Автор

for x in range(1, 101):
if x%4 is 0:
print(x, "is a multiple of 4.")

else:
print(x)

ratankumartakhellambam
Автор

when you realize hes staying up in the night just for us😂 (hes recording at 12 am)

rxcoil
Автор

for n in range(101):
if n%4 is 0:
print("you are done it is ", n)
break
else:
print("Go on")

adityarajtiwari
Автор

i made a mistake, but as it turns out...
for n in range (1, 20):
if n not in numbers:
print(n)
using that 'not' does the same thing here

gurbaajsingh
Автор

I love Bucky, really appreciate what you do for us.

gn
Автор

Hey Bucky! I have found a friend in you! You are a teacher, friend and an anti depressant! Hoped your cardboard got properly recycled.

pankajkhajouria
Автор

thanks for not forgetting about continue ;)

willlywillly
Автор

for x in range(4, 101, 4):
print(x, "is divisible by 4")

emmapederson
Автор

for n in range(101):
if n % 4 == 0:
print(n)

farook
Автор

for n in range(1, 101):
x=n%4
if x is 0:
print(n)
else:
continue
i am finally learning bucky...u r awesome

anishpandey
Автор

#write a program to print all odd numbers between 1 and 40.

givenList = [2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28.30, 32, 34, 36, 38, 40]

for number in range (1, 40):
if number in givenList:
continue
print (number)

tannerbarcelos
Автор

alternatively, you can use 'not in' to make this work.

for f in range (0, 20):
if f not in numbersTaken:
print(f)
elif f in numbersTaken:
continue

camb
Автор

for f in range (0, 20):
if ranonce is 0:
print("the numbers available...")
ranonce = 1
if f in numbersTaken:
continue
else:
print(f)

I used a trigger variable to run something only once in a loop.

camb