Find the HCF and LCM of two number. public class HCF { static int absFun(int num){ return(num>0?num:(-num)); } int calculateHCF(int

Continue reading## Convert string into number in java

A string contains a number such that string str=”1023″; then calculate a number num=1023; call method int convertStringToNumber(char []myNumber);

Continue reading## Call by value and call by reference in java

In java there is only call by value is possible. We achieve call by reference using call by object in

Continue reading## Swap two strings without using any variable

Swap two strings without using any variable public class SwapTwoStringWithoutUsingVaraible { public static void main(String[] args) { String a=”delhi”; String

Continue reading## Swap two character without using any variable

Swap two character with out using any variable: public class SwapTwoCharacterWithoutUsingVaraible { public static void main(String[] args) { char ch1=’A’;

Continue reading## How to check Missing and Repeated number in array

A array size n have element 1-n but one element is missing and one element is repeated . public class

Continue reading## Check number even or odd without using modulo operator

Check given number is even or odd without using modulo operator. for this we use & operator. if any number

Continue reading## Factorial program using recursion in java

Java program for factorial using recursion public class factorial { int fact(int n){ if (n==1) {

Continue reading## Get a number from a string in java

How to get number from a string which contains number : example string str=”123″;

Continue reading## Add Two Big Number In Java

We have two big number such that out of range of Integers then, how are you add these number. we

Continue reading