0

Chatbot v1.0 Stuck

Not understanding how to separate input() between Test Cases 1-3 Tom, Alice and Bob. I’ve tried hints and gone back thru lessons but haven’t be able to figure it out. Can someone here give a little help?

23rd Jan 2024, 1:49 PM
Jonathan Austin
7 Respuestas
+ 2
name=input() NOT name="Bob" The task instruction tells you to take INPUT.
24th Jan 2024, 1:49 PM
Lisa
Lisa - avatar
+ 4
show your code
23rd Jan 2024, 1:59 PM
Lisa
Lisa - avatar
+ 4
I think you might be misunderstanding the exercise. Your code should take a name as input, doesn't matter what the name is and output the message with the name in it. So, you allocate the input to a variable and put that variable in your print statement.
23rd Jan 2024, 3:13 PM
Ausgrindtube
Ausgrindtube - avatar
+ 2
You are supposed to take input() – not hard-code "Bob"?
24th Jan 2024, 12:17 PM
Lisa
Lisa - avatar
+ 1
Thank tou for you patience and info, got it # Ask the user for input and store it in a variable name = input() # Display the user input on the screen print(name)
24th Jan 2024, 6:37 PM
Jonathan Austin
0
Thanks for responce, I understand that part. What has me stumped is the 3 Test Cases, when I run name=“Bob” print(name) I get Bob output But, Bob is being output to Test Cases #2 and #3, that are requesting different names, which makes them incorrect and im unable to pass that exercise. Unfortunatly Im unable to attatch screen shots so it is a bit hard explaining.
24th Jan 2024, 12:02 PM
Jonathan Austin
0
It is telling me the expected output is Bob in the description before exercise. Its the multipul Test Cases, each Case is on its own drop down window. Test Case 1 Expected Output is Bob Test Case 2 Expected Output is Alice Test Case 3 Expected Output is Tom When I run code name=“Bob” print(name) for Test Case 1, it is being applied to All Test Cases at the same time.
24th Jan 2024, 1:41 PM
Jonathan Austin