Choose Your Language

Thursday, 12 September 2013

How to add two numbers without using "+" symbol

public class AdditionWithoutPlusSymbol{
    public static void  main(String args[]){
        int a,b,c;
        a=10;b=20;
        c=(a-(-b));
        System.out.print("Addition Result is "+c);
    }
}

output:
Addition Result is 30

No comments:

Post a Comment