Today this python script that will show whether a string is palindrome or not .
This script will work on pythoon3 and above .
copy bellow script to a file say its 1.py
a=str(input('Give a string: '))
d=len(a)
b=[]
for i in range (d):
b.append(a[i])
c=[]
e=len(b)
for i in range(e):
c.append(b[(e-1)-i])
if b==c:
print('Given',a,'is a palindome.')
else:
print('No',a,'is not a palindrame.')
Now Run the script as : python3.4 1.py
You will get the following output .
This script will work on pythoon3 and above .
copy bellow script to a file say its 1.py
a=str(input('Give a string: '))
d=len(a)
b=[]
for i in range (d):
b.append(a[i])
c=[]
e=len(b)
for i in range(e):
c.append(b[(e-1)-i])
if b==c:
print('Given',a,'is a palindome.')
else:
print('No',a,'is not a palindrame.')
Now Run the script as : python3.4 1.py
You will get the following output .
The best titanium magnetic slots with an - iTanium Art
ReplyDeletePlant slot machines · titanium necklace Plant slot machines titanium element · Plant slot machines · Plant ridge titanium wallet slot machines titanium sheet · Plant slot machines titanium element
ba814 on running trainers,keen footwear uae,caterpillar deutsch,caterpillar portugal,mizuno tenis,scarpealtra,Caterpillar boty,zapatillaskeen,asics australia sf903
ReplyDelete