Skip to content
Programmingoneonone
Programmingoneonone
  • Engineering Subjects
    • Internet of Things (IoT)
    • Digital Communication
    • Human Values
  • Programming Tutorials
    • C Programming
    • Data structures and Algorithms
    • 100+ Java Programs
    • 100+ C Programs
    • 100+ C++ Programs
  • Solutions
    • HackerRank
      • Algorithms Solutions
      • C solutions
      • C++ solutions
      • Java solutions
      • Python solutions
    • Leetcode Solutions
    • HackerEarth Solutions
  • Work with US
Programmingoneonone
Programmingoneonone

HackerEarth Palindromic Ciphers problem solution

YASH PAL, 31 July 202413 February 2026
In this HackerEarth Palindromic Ciphers problem solution Julius Cipher is a type of cipher which relates all the lowercase alphabets to their numerical position in the alphabet, i.e., the value of a is 1, the value of b is 2, the value of z is 26, and similarly for the rest of them.
 
Little Chandan is obsessed with this Cipher and he keeps converting every single string he gets, to the final value one gets after the multiplication of the Julius Cipher values of a string. Arjit is fed up with Chandan’s silly activities, so he decides to at least restrict Chandan’s bad habits.
 
So, he asks Chandan not to touch any string which is a palindrome, otherwise, he is allowed to find the product of the Julius Cipher values of the string.
 
 
HackerEarth Palindromic Ciphers problem solution

 

 

HackerEarth Palindromic Ciphers problem solution.

x = "abcdefghijklmnopqrstuvwxyz"
y = list(x)
tc = int(raw_input())
while tc>0:
tc = tc - 1
s = raw_input()
if s==s[::-1]:
print "Palindrome"
else:
ans = 1
for i in s:
ans = ans * (y.index(i)+1)
print ans
 
coding problems solutions HackerEarth HackerEarth

Post navigation

Previous post
Next post

Leave a Reply

Your email address will not be published. Required fields are marked *

Programmingoneonone

We at Programmingoneonone, also known as Programming101 is a learning hub of programming and other related stuff. We provide free learning tutorials/articles related to programming and other technical stuff to people who are eager to learn about it.

Pages

  • About US
  • Contact US
  • Privacy Policy

Practice

  • Java
  • C++
  • C

Follow US

  • YouTube
  • LinkedIn
  • Facebook
  • Pinterest
  • Instagram
©2026 Programmingoneonone | WordPress Theme by SuperbThemes