0

How do I create x is greater than or equal to 0 but less than or equal to 10 in Python?

I have tried x >= 0<= 10 and x >= 0 or <= 10

25th Jul 2019, 2:10 PM
Powersurge
Powersurge - avatar
5 Answers
+ 1
Thanks. I am working on a BMI program and I will need to define output in that range to give proper advise to users.
25th Jul 2019, 2:17 PM
Powersurge
Powersurge - avatar
+ 1
0 <= x <= 10
25th Jul 2019, 4:16 PM
Seb TheS
Seb TheS - avatar
0
Try x>=0 and x<=10 instead of x>=0 or <=10
26th Jul 2019, 4:46 AM
Iqbal Khan
Iqbal Khan - avatar
0
Ikbal Khan your suggestion works. Thanks.
26th Jul 2019, 9:22 AM
Powersurge
Powersurge - avatar