0

can someone tell me what is error in thise . I am a beginner plz help .

X=int(input("enter a number")) If xĂ·2==0: Print(x,"is even") Else: Print(x,"is odd")

26th Apr 2020, 4:55 AM
Amarjit Sandhu
Amarjit Sandhu - avatar
2 Answers
+ 2
That is not a valid operator in python. % is the correct operator for modulus
26th Apr 2020, 4:59 AM
Bhavya
Bhavya - avatar
+ 1
From line2 please remove Ă· operator and use% (modulo operator) Ă· is not an operator in python... %(modulo operator) is used to give remainder
26th Apr 2020, 5:26 AM
ANJALI SAHU