+ 3
How to answer all test cases
Hello I need help with 16.2 , well the first test case, I did, but there more case tests, my first code interrupt with the second test case 2. How I separate them. First case *** hello *** and second test *** python is awesome *** ...
16 Answers
+ 6
You have to use input()
It will be different for each test case
+ 3
Hi yuri kelner
Please review lesson 16.1 of "Python for Beginners" as it directly relates to the problem you are having.
as Benjamin Jürgens has stated, input() will be helpful
+ 1
yuri kelner
If your code correct all test cases will be passed !
+ 1
yuri kelner
Well done!
😁👍
+ 1
You need to write one code which will pass both the test cases. Test case 1 and test case 2 are sample inputs which means if you enter either hello or awesome you should be able to output *** hello*** or *** awesome***, whichever given as input.
var = input()
print("***" + var + "***")
Input - hello
Output - ***hello***
Hope this helps!
+ 1
my first case is satisfied but when i m attempting the second case then first case becomes unsatisfied how can i do both the test case in transportation problem
+ 1
string = input(" ") [::-1]
print(string) ;
+ 1
Hello sololeaners l need some assistance , completed my first test case when attempting the second case vanishes.
name_1="hello"
print("***"+name_1+"***")
answer()
name_2="awesome is python"
print (("***" +name_2)*(1+valid_tax))
0
Well, now you gotta think outside the box, try stuff, fail. Thats how you learn
0
Thank you very much everyone!!!!❤️
I got it 🙂
0
IN C++ ??? is input() or diferent
0
Luis Alfredo Villamizar López
cin >> variable
There are a number of different formats.
Create a separate question from this thread and post it, you should get a number of responses showing you how to do it.
0
text= input("")
print ("*** "+text+" ***")
- 2
I don't know how to continue. The first case is correct, but second case is to write python is awesome.
Name=(" hello ")
Print("***" + name + "***")
- 2
I solved the first and the second case separately, but still don't have idea, how to connect them. 3-4 hidden.
name=(" hello ")
name2=(" python is awesome ")
Print ("***" + name2 + "***")