0
Python introduction issues
Im on chatbot v1.0 and Im stuck. I understand the task however there are 3 case tests and I can only pass 1 without making the others incorrect. I cannot progress without completing this. I believe it could be a technical error?
7 Answers
+ 6
Jessie Miller ,
to see what your issue is, we need to see your code.
> put your code in playground, save it and post a link to it here.
+ 6
Ausgrindtube , Jessie Miller ,
the task to solve in this exercise is:
> input a name and store it in a variable
> output the name
this is the given *code* from sololearn:
# Ask the user for input and store it in a variable
name =
# Display the user input on the screen
> so we need the input() function for the first line
> and the print() function for the second line.
+ 4
I believe that you're doing what is called "hard coding". This is where you are writing a solution for 1 case only.
Let's take a simple maths example:
Make a program that adds 2 numbers.
Case 1: a = 2, b = 2
Hardcode answer:
print(4)
Or print(2 + 2)
This works for case 1, but not
Case 2: a = 5, b = 8
You need to think of a way to write for all possible a's and b's.
E.g. a = int(input())
b = int(input())
print(a + b)
In order for us to help, can you please do what the following code says:
https://code.sololearn.com/Wek0V1MyIR2r/?ref=app
+ 3
Oluwafemi David ,
Jacinto Tejera GonzĂĄlez ,
it is better for you to start your own post, otherwise poeple will not get aware of you. please also include your current code in the post.
+ 2
Thanks Lothar, let's see if we get the codes from the posters so we can help them.
0
Hi i am also having this issues please cant get past it and i have been looking for a solution
0
https://www.sololearn.com/learn/courses/JUMP_LINK__&&__python__&&__JUMP_LINK-introduction/code-coach/988897365?returnUrl=/learn/courses/python-introduction?location=2
that is the link to the problem i am facing in introduction to python