Correct the logical error in the given Python códe and also explain your answer. n=int(input("Enter a number - "))
if n%5:
print("Number is divisible by 5.")
else:
print("Number is not divisible by 5.")
Share
Correct the logical error in the given Python códe and also explain your answer. n=int(input("Enter a number - "))
if n%5:
print("Number is divisible by 5.")
else:
print("Number is not divisible by 5.")
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
0 Replies