Advertisement
Guest User

Untitled

a guest
Dec 11th, 2019
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. napis = str(input("Podaj zdanie: "))
  2. slowa = [" ", ",", ".", "!", "@", ";", "\"", "\\", "?"]
  3. for i in slowa:
  4. napis = napis.replace(i, "")
  5. if(napis=="".join(reversed(napis))):
  6. print("To zdanie to palindrom")
  7. else:
  8. print("To zdanie to nie palindrom")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement