老师,这个代码if函数总显示 invalid syntax 然后无法运行

来源:6-10 常量与Pylint的规范

cmlc_superV

2019-03-18

为什么这个代码 if 函数下面提示“invalid syntax“图片描述

写回答

3回答

cmlc_superV

提问者

2019-03-18

account='12345'

password='0517'


user_account=input()

user_password=input()


if user_account=account and user_password=password

print('success')

else:

print('fail')


即使不采用‘:’也是不行

0
0

7七月

2019-03-18

冒号是不是不对啊?

0
1
cmlc_superV
已解决 if 语句冒号在 条件后 不在if 后
2019-03-18
共1条回复

qq_猪小擎

2019-03-18

if后面的冒号可能是中文冒号

0
0

Python3.8系统入门+进阶 (程序员必备第二语言)

语法精讲/配套练习+思考题/原生爬虫实战

14596 学习 · 4469 问题

查看课程