Write a program to reverse an integer
Source code
num=int(input("Enter an integer: ")) s_num=str(num) print("Original integer: ",num) print("Reversed integer: ",s_num[::-1])
Output
Need a fast expert's response?
and get a quick answer at the best price
for any assignment or question with DETAILED EXPLANATIONS!
Comments
Leave a comment