From the course: Python Data Analysis

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Challenge: Palindromes

Challenge: Palindromes - Python Tutorial

From the course: Python Data Analysis

Start my 1-month free trial

Challenge: Palindromes

(bright electronic music) - [Instructor] For your challenge, you should extend the anagram machinery that we built together to find all palindromic pairs of words in the English language, or at least, in our dictionary. That is, you should find pairs of words that become each other when we reverse the order of their letters. For instance, reward and drawer. That will also include true palindromes, such as radar, where the reverse of the word is the word itself. I'll give you a hint, to reverse a string, go back to what we learned about slicing sequences in Python. This challenge should take you 10 minutes.

Contents