Hi I have a question, does anyone know why when you try to do the practice exercise they don't let you use the input? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Hi I have a question, does anyone know why when you try to do the practice exercise they don't let you use the input?

Example X= input()) Print(x) When you run the program it doesn't let you put the information for the input.when I do It on the code play ground it let me put the information.If any one knows why this happens please let me know.

22nd Jan 2021, 12:15 AM
Alan Restrepo
Alan Restrepo - avatar
14 Answers
+ 2
In code coach the system will itself give input to your input statement and calculate the results and then match with pre existing saved answer
22nd Jan 2021, 1:03 AM
Ayush Kumar
Ayush Kumar - avatar
+ 2
anthony silver you are allowed to take input while solving the code coach problems. It's just that it would be sololearn which will be giving input to your program instead of you. How the sololearn will give input to your program is given along with question statement only, and your program has to work will all the possible used cases and provide strictly correct output in order to pass.
22nd Jan 2021, 1:56 AM
Arsenic
Arsenic - avatar
+ 1
Indeed. It's like someone else is testing the code on number of different inputs (test cases) And is matching the output with the ones stored with them to check if your program is giving correct answers or not. And as the process is automated and it is just a computer which is evaluating your output, thus your output should be strictly the same as described in questions statement, even an extra character or a typo can yield wrong answer verdict.
22nd Jan 2021, 2:07 AM
Arsenic
Arsenic - avatar
+ 1
Ok thanks , that helps a lot actually, Jesús Crist bless you
22nd Jan 2021, 2:16 AM
Alan Restrepo
Alan Restrepo - avatar
0
Test tasks are checked according to a strict template, and this does not involve arbitrary input data. That's why your input doesn't work there.
22nd Jan 2021, 1:00 AM
Эдуард
Эдуард - avatar
0
Ok thanks , but some of the test tasks I need to use the input, it's something necessary , and I try to do it in other ways but it doesn't work either
22nd Jan 2021, 1:04 AM
Alan Restrepo
Alan Restrepo - avatar
0
Ok that makes sense, because I saw results without I put something, but I try some time's to work with those results but for some reason that I don't know It doesn't work too
22nd Jan 2021, 1:07 AM
Alan Restrepo
Alan Restrepo - avatar
0
We need a specific code example that doesn't work. The question is not clear.
22nd Jan 2021, 1:21 AM
Эдуард
Эдуард - avatar
0
Password=int(input()) x=34 if password==x: print ("Welcome") else: print ("sorry, wrong password, try again") This is an example , lest supposed that In a test task said that they need to make password program and they need that I use the input for put a password and the password has to be with the number 34 . I need to use the input otherwise it would not work, I try to do it and then it tell s me that is wrong, but the code that I use as the example it perfectly works in the code play ground, I tray to do it without the input and just with a variable but again works in the code play ground but not in the test test task
22nd Jan 2021, 1:33 AM
Alan Restrepo
Alan Restrepo - avatar
0
If you do not do what the test task asks, then your code will not work there.
22nd Jan 2021, 1:41 AM
Эдуард
Эдуард - avatar
0
Yes obviously, but what I'm try to explain is that that's exactly the problem because in other test tasks that doesn't involve the input , those works, but with the ones that involves the input, with those are the ones that I have the problems
22nd Jan 2021, 1:50 AM
Alan Restrepo
Alan Restrepo - avatar
0
Ok so you are telling me that sololearn is the one that when I'm doing the task s puts the information for me?
22nd Jan 2021, 2:04 AM
Alan Restrepo
Alan Restrepo - avatar
0
Ok so I have to do in the right way the task , no focuse in the input but in the task it self right?
22nd Jan 2021, 2:11 AM
Alan Restrepo
Alan Restrepo - avatar
0
Yes
22nd Jan 2021, 2:14 AM
Arsenic
Arsenic - avatar