0
Printing multiple messages when there is no input
Is there a way to print multiple messages when there is no input. User_input=input() if not User_input: print("Please enter first value") else: print(User_input) User_input2=input() if not User_input2: print("Please enter second value") else: print(User_input2) If I enter no input or only enter the first input, the second message doesn’t get printed. Is there a way to fix this?
1 Resposta
0
Cannot reproduce that, for me it works, as script and even on sololearn code playground.