Introduction to the example usage of judgment and Loop sentences in Python
This article mainly explains "the introduction of the example usage of judgment and circular sentence in Python". The content of the explanation in this article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "the introduction of example usage of judgment and circular sentence in Python".
1 、 if 、 elif 、 else
Age=17
If age > = 18 and age100:
Print ("longevity baby? ")
Else:
Print ("am I still a baby?")
Console print results:
I'm still a baby?
2. While cycle
Age=0while age