I have tried to solve this but it bringing error | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

I have tried to solve this but it bringing error

purity = float(input()) #your code goes here If purity > 99.9 \\ purity >=91.7: print ("Accepted")

29th Aug 2021, 8:46 PM
Adebisi Olawale
Adebisi Olawale - avatar
3 Answers
+ 5
Note that ‘\\’ is not used in Python. Instead, you may use ‘or’. Try this: if purity > 99.9 or purity >= 91.7:
29th Aug 2021, 8:47 PM
Wenkai Qu
Wenkai Qu - avatar
+ 3
# And you can actually simplify it even more: if 91.7 <= purity < 99.99: print("Accepted")
29th Aug 2021, 9:09 PM
Per Bratthammar
Per Bratthammar - avatar
+ 1
Thanks sir
29th Aug 2021, 9:12 PM
Adebisi Olawale
Adebisi Olawale - avatar