Today programm on palindrom and square of a list

x=int(input(“enter the value”))
num=x
y=0
while(x>0):
div=x%10
print(div)
y=y*10 + div
print(y)
x=x//10
print(x)
if (y==x):
print(" the number is palindrome")
else:
print("the number is not palindrom ")

#square
num=[1,2,3,4]
square=[i**2 for i in num]
print(square)

2 Likes

@anujkamble07
Well done, keep it up.