QUESTION IMAGE
Question
question # 2
multiple select
which statements will ask the user for a number? select 2 options.
answer = input(\how many sodas do you want? \)
answer = input(how many sodas do you want? )
answer = input(how many sodas do you want? )
answer = in(\how many sodas do you want? \)
answer = in(how many sodas do you want? )
In programming, the input() function is used to get user - input. The proper syntax requires the prompt string to be inside quotes (single or double). The functions in and input without quotes around the prompt are incorrect. The first two options use the input() function correctly with the prompt string inside quotes and ask for a number as indicated by "How many".
Snap & solve any problem in the app
Get step-by-step solutions on Sovi AI
Photo-based solutions with guided steps
Explore more problems and detailed explanations
A. answer = input("How many sodas do you want? ")
B. answer = input('How many sodas do you want? ')