FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
javaprogram/Palindrome at master · devesh-dev/javaprogram · GitHub
devesh-dev
javaprogram
Repository navigation
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
javaprogram
/
Palindrome
Copy path
More file actions
More file actions
Latest commit
History
History
History
17 lines (16 loc) · 413 Bytes
Breadcrumbs
javaprogram
/
Palindrome
Copy path
File metadata and controls
17 lines (16 loc) · 413 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
class PalindromeExample{
public static void main(String args[]){
int r,sum=0,temp;
int n=454;//It is the number variable to be checked for palindrome
temp=n;
while(n>0){
r=n%10; //getting remainder
sum=(sum*10)+r;
n=n/10;
}
if(temp==sum)
System.out.println("palindrome number ");
else
System.out.println("not palindrome");
}
}
Back
|
FazBrowse Home
|
New Git URL