Description: |
Write a sample code to Swapping of two Numbers in java without third variable. |
Code: | ||
|
Output: |
Enter x and y no:
10
20
Before Swaping
x=10
y=20
After Swaping
x=20
y=10
|
Description: |
Write a sample code to Swapping of two Numbers in java without third variable. |
Code: | ||
?
|
Output: |
Enter x and y no:
10
20
Before Swaping
x=10
y=20
After Swaping
x=20
y=10
|
Description: |
Write a sample code to Palindrome in java. |
Code: | ||
?
|
Output: |
Enter a string to check :
madam
The string is a palindrome.
Enter a string to check :
godblessgovind
The string isn't a palindrome.
|
Description: |
Write a sample code to FizzBuzz Program in Java. |
Code: | ||
?
|
Output: |
1 2 Buzz 4 fizz Buzz 7 8 Buzz fizz 11 Buzz 13 14 fizzBuzz |
Description: |
Write a sample code to print Fibonacci Series using for loop in java. |
Code: | ||
?
|
Output: |
0
1
1
2
3
5
8
13
21
34
55
89
144
233
377
|
Description: |
Write a sample code for Factorial in java.. |
Code: | ||
?
|
Output: |
Factorial of : 5
Factorial is : 120
|
Description: |
Write a sample code to check Even OR Odd using scanner in java. |
Code: | ||
?
|
Output: |
Enter the Number:
12
Number is Even
|