
how to write an addition program in java without using arithematic operator +?

Add numbers without using Operator
We are providing you two ways:
1)
import java.math.*;
class AddNumbers
{
public static void main(String[] args)
{
BigInteger num1=new BigInteger("100");
BigInteger num2=new BigInteger("50");
BigInteger result=num1.add(num2);
System.out.println(result);
}
}
2)
public class AddNumberUsingBitwiseOperators {
public static void main(String[] args) {
System.out.println("Adding 5 and 6......");
int x=5,y=6;
int xor, and, temp;
and = x & y;
xor = x ^ y;
while(and != 0 )
{
and <<= 1;
temp = xor ^ and;
and &= xor;
xor = temp;
}
System.out.println(xor);
}
}