
Palindromes in Sanskrit
I was just teaching my kid some programming, and we were writing code to figure out whether a given word or sentence was a palindrome. A palindrome is a string that reads the same from each end. "Madam, I'm Adam" is a palindrome, if you ignore the punctuation. So is "A Toyota," and there are many more words or sentences you could construct in English. Computer scientists typically encounter palindromes early in programming classes as an exercise in string manipulation.
While these palindromes in English are entertaining, they're often random, unintelligible sentences strung together just to read identically forwards and backwards. But what if I told you that there's an entire class of poetry built entirely from palindromic words, sentences, and even entire cantos?
In Sanskrit, palindromes are known as अनुलोम-प्रतिलोम-पदम् (anuloma-pratiloma-padam). Sanskrit is particularly suited to creating rich palindromes due to its flexible word order, precise grammar, and vast vocabulary, enabling poets to craft meaningful and artistic works.
For example, the poet Sūrya created an extraordinary poem of 30 verses called the Rāmakṛṣṇa Viloma Kāvyam. When read forwards, these verses narrate the epic tale of Rāma from the Rāmāyaṇa. When read backwards, they beautifully recount the story of Kṛṣṇa from the Mahābhārata. Here's a simplified example from Sūrya's poem:
Forward (note the devanagari text):
Backward (the devanagari text is an exact palindrome!):
Sanskrit literature contains many such fascinating examples. A particularly striking example is Bhāravi’s Kirātārjunīya, composed in the 6th century. Bhāravi created a poem that forms a two-dimensional palindrome, meaning the verses read identically in multiple directions, adding yet another layer of complexity and elegance.
