Find the error in the following code and write the corrected code after underlining the errors of
the incorrect code:
n=int(intake(“Enter a number”))
if n%10==0
print(‘The number is divisible by 10”)
else:
print[‘Number is not divisible by 10’]
Answers
Answered by
0
Answer:
if n%10===0
Explanation:
there should be a triple equal to ===
print[‘Number is not divisible by 10’] here there shuld be double quotes I thinkn
Answered by
8
n=int(intake(“Enter a number”))
if n%10==0
print(‘The number is divisible by 10”)
else:
print[‘Number is not divisible by 10’]
n=int(input(“Enter a number”))
if n%10==0:
print('The number is divisible by 10')
else:
print(‘Number is not divisible by 10’)
Similar questions