Is there a difference between `continue` and `pass` in a for loop in python?

Is there any significant difference between the two python keywords continue and pass like in the examples

for element in some_list:
    if not element:
        pass

and

for element in some_list:
    if not element:
        continue

I should be aware of?

12 Answers
12

Leave a Comment