without using arthematic operation ,how can you write the
logic for adding/substraction/multiplication?
Answer Posted / ashwinkumar
int a = 10;
int b = 5;
int sum = BigInteger.valueOf(a).add(BigInteger.valueOf(b)).intValue();
int sum1 = BigInteger.valueOf(a).subtract(BigInteger.valueOf(b)).intValue();
int sum2 = BigInteger.valueOf(a).multiply(BigInteger.valueOf(b)).intValue();
Is This Answer Correct ? | 2 Yes | 3 No |
Post New Answer View All Answers
What are bind parameters?
What is procedure writing?
What is procedure overloading?
Can we override the private methods?
why are there separate wait and sleep methods? : Java thread
Why does my function print none?
How do you trim a space in java?
Differentiate between run time error and syntax error.
Give some features of interface?
Is assembly language a low level language?
Explain about method local inner classes or local inner classes in java?
What is difference between classpath and path variables in java?
What is a variable and constant?
What is object of class in java?
How can I debug the Java security exceptions and AccessControlExceptions?