+ 1

Anyone correct my code

Please anyone help me "5 < x <= 10" how to write this on python https://code.sololearn.com/c4Nwhp4FEmC9/?ref=app

20th Feb 2020, 5:37 PM
Akash Kumar
Akash Kumar - avatar
22 ответов
+ 3
Álvaro Estévez López You can use 5 < x <= 10 directly.
20th Feb 2020, 8:48 PM
Mihai Apostol
Mihai Apostol - avatar
+ 7
Madison please don't be rude to fellow members trying to help keep you out of trouble.
21st Feb 2020, 11:12 PM
bobbie
bobbie - avatar
+ 3
Madison again, please don't spam in the answers. I will not reply further to any messages.
21st Feb 2020, 10:49 PM
Aymane Boukrouh
Aymane Boukrouh - avatar
+ 2
Ok, good. First to read the input you need x = int(input()) Then you need to output exact texts from the challenge description. Now you can continue from here. You need to change a little bit the logic in the if-elif statements. Can you do it?
20th Feb 2020, 5:50 PM
Mihai Apostol
Mihai Apostol - avatar
+ 2
Madison don't spam in the answers please.
21st Feb 2020, 12:34 AM
Aymane Boukrouh
Aymane Boukrouh - avatar
+ 1
Don't think Batman understands hindi. Post complete code from playground.
20th Feb 2020, 5:43 PM
Mihai Apostol
Mihai Apostol - avatar
20th Feb 2020, 5:46 PM
Akash Kumar
Akash Kumar - avatar
+ 1
"5 < x <= 10" how to write this on python
20th Feb 2020, 5:47 PM
Akash Kumar
Akash Kumar - avatar
+ 1
Ok i understood thank you sir
20th Feb 2020, 5:53 PM
Akash Kumar
Akash Kumar - avatar
+ 1
Akash Kumar Exactly like that, though I guess you need 5 <= x <= 10
20th Feb 2020, 5:53 PM
Mihai Apostol
Mihai Apostol - avatar
+ 1
(5,10) 5 is included in this range or not?
20th Feb 2020, 5:54 PM
Akash Kumar
Akash Kumar - avatar
+ 1
Akash Kumar Sorry I don't understand this last question.
20th Feb 2020, 5:56 PM
Mihai Apostol
Mihai Apostol - avatar
+ 1
Lets say we will play if there are (5,10) players on ground, so in this situation if there are 5 players on the ground shall we play or not
20th Feb 2020, 6:01 PM
Akash Kumar
Akash Kumar - avatar
+ 1
Here (5,10) means [5,6,7,8,9,10] or [6,7,8,9,10] ?
20th Feb 2020, 6:02 PM
Akash Kumar
Akash Kumar - avatar
+ 1
Akash Kumar If there are 5, 6, 7, 8, 9, 10 bad guys you need to call Batman, so yes 5 is included.
20th Feb 2020, 6:06 PM
Mihai Apostol
Mihai Apostol - avatar
+ 1
Ok thanks i solved this question thank you sir
20th Feb 2020, 6:07 PM
Akash Kumar
Akash Kumar - avatar
+ 1
Akash Kumar You're welcome.
20th Feb 2020, 6:11 PM
Mihai Apostol
Mihai Apostol - avatar
+ 1
x = int(input()) if x < 5: print('i can handle this') elif x >= 5 and x <= 10: print("batman help me!") else: print("Good Luck batman!")
22nd Feb 2020, 6:21 AM
Edgar Minasyan
Edgar Minasyan - avatar
22nd Feb 2020, 10:56 AM
fatal1ty
fatal1ty - avatar
+ 1
#include <iostream> using namespace std; int main() { cout << "batman help me! \n\n"; cout << "Good Luck batman!"; return 0; }
22nd Feb 2020, 11:44 AM
fatal1ty
fatal1ty - avatar