Not passing al testcases

Code:
//package strings;
import java.util.*;
public class Main {

public static void main(String[] args) {
	Scanner in = new Scanner(System.in);
	String x = in.nextLine();
	StringBuilder sb = new StringBuilder(x);
	boolean y =isPalindrome(sb);
	System.out.println(y);
}
public static boolean isPalindrome(StringBuilder sb1)
{
	if(sb1.equals(sb1.reverse()))
		return true;
	return false;
}

}

Hi bharat
For checking palindromic strings, chracters equidistance from 1st position and last position must be equal.

public static boolean palindrome(String str){

      int n = str.length();
      for(int i =0;i< n/2;i++){

          if(str.charAt(i) != str.charAt(n - i - 1)){
              return false;
          }
      }

      return true;
  }