python学习之if语句
2016-11-04 12:35
253 查看
1.if条件表达式判断
View Code
user="desperado pwd="123456" username=input("用户名:") password=input("密码:") if username == user and password == pwd: print("login successful ...") elif username != user: print("the user does not exist") else: print("login fail")
View Code
相关文章推荐
- Python学习入门基础教程(learning Python)--3.1Python的if分支语句
- Python学习(3)——if语句
- python学习小结2:if和while控制语句
- python 学习笔记 if语句(10)
- Python学习笔记(4)-if语句
- Python学习笔记(九):if、while、for语句
- python 学习笔记 if语句
- Python学习笔记(二)if语句的简单用法
- Python新手学习基础之条件语句——if/else语句
- python控制流语句if、while、for、break、contnue的学习———ubuntu下python的学习(2)
- Python学习入门基础教程(learning Python)--3.2 if-else分支语句 .
- Python学习笔记四:if语句
- [python学习手册]if语句
- python 学习之cmd下的if语句
- python 学习笔记 if语句
- Python学习入门基础教程(learning Python)--3.3.4 Python的if-elif-else语句
- Python学习笔记四:if语句
- python学习小结2:if和while控制语句
- python学习2——if语句、elif、if嵌套、while循环、while嵌套
- python学习之if语句