()
| 2 | class palindrome |
| 3 | { |
| 4 | public static void main() |
| 5 | { |
| 6 | Scanner sc= new Scanner(System.in); |
| 7 | System.out.println("enter a number"); |
| 8 | int num= sc.nextInt(); |
| 9 | int d,num1,rev;rev=0; |
| 10 | num1=num; |
| 11 | while(num!=0) |
| 12 | { |
| 13 | d=num%10; |
| 14 | rev=rev*10+d; |
| 15 | num=num/10; |
| 16 | } |
| 17 | if(num1==rev) |
| 18 | System.out.println("the number is palindromic"); |
| 19 | else |
| 20 | System.out.println("the number is not palindromic"); |
| 21 | } |
| 22 | } |
| 23 | |
| 24 |
nothing calls this directly
no outgoing calls
no test coverage detected