- 1
Python - Answers checked as correct but then change after next entry. 16.2
Output looking for - *** hello *** My code - Case1 = “*** hello ***” print(Case1) Gets marked as correct. But after I do Case 2., also checked as correct, but simultaneously unchecked Case1. Very frustrated. Help sucks and no way to get past this.
6 Réponses
+ 2
Simon: it worked! Thank you. Now following you. Much appreciated.
+ 1
You have to write one single code that passes all test cases.
+ 1
The cases are only locked in the sense that you can't see them. When you submit your code sololearn runs a number of test cases. Each test case consists of sololearn providing some input for your code and checking whether your code produces the correct output.
So what you have to do is write a program that takes input works with it and produces output. It has to work both for known input (the cases that are open) and unknown input (the cases that are locked).
0
did you a if statement?
Then I would say use elif instead.
And if you use the match function. (not working on SoloLearn in this moment)
Then use break inside the case.
0
Please give the description of the assignment.
0
Thanks for the replies
Carrie: Problem 16.2
Stef: Im not that far, section 16.2 hasnt reached if and elif.
Simon: Not sure how that would work. Case 3 and 4 are locked until i finish 1 and 2.
Is it something like….
Name = input()
print(“*** “ + Name + “ ***)
Is there anyway to just get the answer from ‘help’ instead of spending an hour on one problem?