how can program polindrome using java
import java.lang.*;
class Plindrome
{
public static void main(String arg[])
{
int n=121,m;
int rev,rem;
rev=0;m=n;
while(n>0)
{
rem=n%10;
rev=rev*10+rem;
n=n/10;
}
if(m==rev)
{
System.out.println("palindrome",+rev);
}
else
{
System.out.println("not palindrome",+rev);
}
}
}
| Is This Answer Correct ? | 2 Yes | 0 No |
Why java is better than node.js?
What happens if javac is not recognized?
How do I export a java project?
ioc vs dependency injection?
What is dto layer in java?
what is jdbc?
What is factory pattern in java?
Which class is the superclass of every class?
What does jpa mean?
what is major difference between component and object?
Input :14000 Output : hundred and fourteen thousand.(wrong) Desired output : fourteen hundred thousand.
What about products that claim to block java applets at a firewall? : java security