как правильно записать на место чёрточек вставить знаки пожалуйста | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

как правильно записать на место чёрточек вставить знаки пожалуйста

x = 10 y = 20 - x > y- print("if statement") print("else statement")

2nd Dec 2019, 4:21 PM
751157
751157 - avatar
9 Answers
+ 1
спасибо
22nd Dec 2019, 2:48 PM
751157
751157 - avatar
+ 2
"-x" is the negation of x. "-y" is the negation of y. Basically speaking, if you have x=2 and y=3, then... -x>-y ... is the same as... -2>-3 In this case, it is True. It depends on the values, evidently. Also: -x>-y is the same as... y>x Hope I could help! :)
2nd Dec 2019, 6:02 PM
Gonçalo Magalhaes
Gonçalo Magalhaes - avatar
+ 1
Gonçalo Magalhaes we are still learning to formulate the problem in our native language :)
2nd Dec 2019, 5:53 PM
Petr
+ 1
Gonçalo Magalhaes Do you know what is "-x>y-" in python? I have many ideas, but what does the author mean? this is what I find out..
2nd Dec 2019, 5:58 PM
Petr
+ 1
Gonçalo Magalhaes You Replace y- :)) it is only one variant
2nd Dec 2019, 6:05 PM
Petr
+ 1
You're right! If that is the case, it is an error, it will lead to a SintaxError being raised.
2nd Dec 2019, 6:07 PM
Gonçalo Magalhaes
Gonçalo Magalhaes - avatar
0
751157 Дано x=10, y=20. Ecли -10>20- , то что на выходе?
2nd Dec 2019, 5:23 PM
Petr
0
I guess if you ask the question in English, you'll get much more help :)
2nd Dec 2019, 5:48 PM
Gonçalo Magalhaes
Gonçalo Magalhaes - avatar
0
Sure! What is the question?
2nd Dec 2019, 5:53 PM
Gonçalo Magalhaes
Gonçalo Magalhaes - avatar