显然我的代码有问题.当我使用Python 3.3.3 Shell运行以下模块时,我收到错误SyntaxError: expected an indented block.然后IDLE突出显示elif在第7行.
def user_input():
print('[1]: ASCII to Binary')
print('[2]: Binary to ASCII')
user_input = input('Please choose [1] or [2]: ')
if user_input == ('1', '[1]'):
#
elif user_input == ('2', '[2]'):
#
else:
print('Please enter a valid input...')
user_input()
Run Code Online (Sandbox Code Playgroud)