Frequently Asked Java Program 02: Java Program to Check if Any String is Palindrome Without Using Reverse Method

Hello Folks,

As part of Frequently Asked Java Programs In Interviews For Freshers And Experienced,  in this post we will see a Java program to verify if a given string is palindrome without using inbuilt reverse method.


A palindromic string is a string that remains the same when its characters are reversed.

For Example: NAAN, AMMA AMMA etc.


Since we can not use built in reverse method, so we will use different logic.

  1. We will convert given string in to char array first.
  2. Read char from char array from last index and concatenate.

Java Program:


Please enter the string to check palindrome:
Inout string:NANA
Reverse String:ANAN
Entered string is not palindrome.
Please enter the string to check palindrome:
Inout string:AMMA
Reverse String:AMMA
Entered string is palindrome.

You can run above program for multiple inputs and if it fails for any condition, let me know.


Author: Amod Mahajan

My name is Amod Mahajan and I am an IT employee with 6+ years of experience in Software testing and staying in Bengaluru. My area of interest is Automation testing. I started from basics and went through so many selenium tutorials. Thanks to Mukesh Otwani as his tutorials are easy and cover basics to advance. I have habit of exploring concepts by deep diving. I used to make notes. I thought of sharing my knowledge through posts and now I am here. #KeepLearning #ShareLearning

Leave a Reply

Please wait...

Subscribe to new posts to become automation expert

Want to be notified when my new post is published? Get my posts in your inbox.
%d bloggers like this: