addition

addition

write a program to add two numbers without using variables

View Answers

February 22, 2011 at 12:12 PM

Java add two numbers

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);
    }
}









Related Tutorials/Questions & Answers:
Addition of JComboBoxItem
Addition of JComboBoxItem  how to add JComboBoxItem cb1=1,cb2=1/9 into a JTextField. thanks
addition
Advertisements
Addition of two numbers
Addition of two numbers  addition of two numbers
Matrix Addition using RMI in Java
Matrix Addition using RMI in Java  Source Code for Matrix Addition using RMI in Java
MySQL Addition
MySQL Addition       MySQL Addition returns you the sum value of a specific column for a group in a table. The Aggregate function sum() is used to perform the addition in SQL
ModuleNotFoundError: No module named 'math-addition'
ModuleNotFoundError: No module named 'math-addition'  Hi, My... 'math-addition' How to remove the ModuleNotFoundError: No module named 'math-addition' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'shivam-addition'
ModuleNotFoundError: No module named 'shivam-addition'  Hi, My... named 'shivam-addition' How to remove the ModuleNotFoundError: No module named 'shivam-addition' error? Thanks   Hi, In your python
MySQL Addition
MySQL Addition       MySQL Addition returns you the sum value of the total counts in a table..._TO_REPLACE_1 The Tutorial illustrate an example from 'MySQL Addition
Preprocessor directive case for multiplication and addition
Preprocessor directive case for multiplication and addition  Preprocessor directive case for multiplication and addition include<stdio.h> define m 2+10 include<conio.h> int main() { int i; clrscr
Addition to my previous post - Java Beginners
Addition to my previous post  Addition to my previous question about the address book program. I need to have separate classes: CmdLineAddressBook.java AddressBook.java Contact.java Address.java Name.java
matrix addition
matrix addition
PHP Addition of Array
PHP Addition an Array to Another Array In this PHP beginners tutorial we will study to add an array into another array, don't be confused with array merge and addition of arrays, given example will clear the confusion, in the given
binary addition,subtraction and modulus operations - Java Beginners
binary addition,subtraction and modulus operations  i wanna perform binary addition,subtraction and modulus operation between two numbers of 512 bit... passed as string into binary form, and then perform addition,subtraction and modulus
ModuleNotFoundError: No module named 'odoo12-addon-base-product-mass-addition'
ModuleNotFoundError: No module named 'odoo12-addon-base-product-mass-addition...: ModuleNotFoundError: No module named 'odoo12-addon-base-product-mass-addition' How...-mass-addition' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'odoo12-addon-base-product-mass-addition'
ModuleNotFoundError: No module named 'odoo12-addon-base-product-mass-addition...: ModuleNotFoundError: No module named 'odoo12-addon-base-product-mass-addition' How...-mass-addition' error? Thanks   Hi, In your python
How to make addition of two combobox values using jsp and javascript?
addition of two combobox values using jsp and javascript  How to make addition of two combobox values using jsp and javascript?  <html> <h2>ComboBox</h2> <script language="javascript"> var arr
Show Addition, Subtraction, Intersection, Exclusive OR on one frame
Show Addition, Subtraction, Intersection, Exclusive OR on one frame       This section illustrates you how to show Addition, Subtraction, Intersection, ExclusiveOR on one frame
Show Addition, Subtraction, Intersection, Exclusive OR on one Frame
Show Addition, Subtraction, Intersection, Exclusive OR on one Frame       This section illustrates you how to show Addition, Subtraction, Intersection, ExclusiveOR on one
how to calculate addition of two distances in feets and inches using objects as functions arguments
how to calculate addition of two distances in feets and inches using objects as functions arguments  how to calculate addition of two distances in feets and inches using objects as functions arguments in java
code for a simple java program which performs basic arithmetic operation addition,subtraction,multiplication,division........
code for a simple java program which performs basic arithmetic operation addition,subtraction,multiplication,division........  code for a simple java program which performs basic arithmetic operation addition,subtraction
Q, 12 WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java
Q, 12 WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java  Q, 12 WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java
WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java
WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java  WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java   
WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java
WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java  WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java   
WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java
WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java  WAP to calculate addition of two distances in feets and inches using objects as functions arguments in java   
Preprocessor directive case for multiplication and addition
Preprocessor directive case for multiplication and addition
Shop and win campaign drive web project in strictly HTML in addition to PHP languages only.(it should have both languages)
Shop and win campaign drive web project in strictly HTML in addition to PHP languages only.(it should have both languages)  Shop N win campaign drive web project. Prime shoppers Ltd a leading shopping center is running
this code gives addition of 2 numbers in j2me..but the code is not executing ..can u pls find out the error...??
this code gives addition of 2 numbers in j2me..but the code is not executing ..can u pls find out the error...??  import javax.microedition.midlet.*; import javax.microedition.lcdui.*; public class add1 extends MIDlet implements
Addition of two arrays element in C
Matrix addition in java
Matrix addition in java In this section we will learn about addition of two...-dimensional array. Here we are going to develop a Java code for matrices addition... } } System.out.println("After addition of the two matrices:-"
PHP date add, PHP Date addition to a date object
Java Matrix Addition Example
Java Matrix Addition Example In this tutorial, you will learn how to find...("Addition Of Matrices: "); for(int i=0;i<C.length;i++){ for(int... Addition Of Matrices: 6 4 6 9 10 7 4 3 8
Addition of two Number in Class
Addition of two Numbers in Class       In this program we will learn how to calculate... in this program  we are going to use addition of  two number. First of all
C Addition of two matrices
C Addition of two matrices In this section, we are going to calculate the sum...;    printf("\nThe Addition of two matrix is:\n"... 6 7 8 The Second matrix is: 5 6 7 8 The Addition of two
Writing and testing method of addition of two numbers
Writing and testing method of addition of two numbers  ... a method named sum() which takes two int parameters and return addition of these two... to test addition functionality of the program. To make these methods of any use our
Mysql Time Operation
Mysql Time Operation       Mysql Time Operation performs the subtraction and addition of time. Understand with ExampleADS_TO_REPLACE_1 The Tutorial illustrate an example from Mysql
Arithmetic Operators
operations like addition, subtraction, multiplication, division, and modulo... ArithmeticDemo.java C:\nisha>java ArithmeticDemo The addition
JavaScript determine add, product of two numbers
JavaScript determine add, product of two numbers In this section, you will learn how to determine addition, multiplication, division and modulus of two numbers. To find this, we have created two textboxes and four button
Java Vector
Java Vector       Introduction to Vector Vector are array list with extended properties which follow the dynamic and automatic addition of data at run-time. Unlike array, Vector
The Arithmetic Operators
that perform the mathematical values addition, subtraction, multiplication...; num1=num2;   }   public int Addition...=Integer.parseInt(object.readLine());   int addition
RMI-Example-2
RMI-Example-2       This example demonstrate the RMI Addition Application. Well in this application you will use the four java files. List of java files
Add Two Numbers in Java
these arguments and print the addition of those numbers. In this example, args... Addition of two numbers! Sum: 32
PHP Arithmetic Operator
Arithmetic Operators: These are the most basic kind of operators. The PHP Arithmetic operator is used to perform addition(+), subtraction(-), Division(/), Multiplication(*), modulus(%). with variable or value. We all have done in our
Get Java Version
Get Java Version       The Java has a lot changes since JDK1.0 as well as numerous additions of classes and packages. In addition to this class and package ,Java introduced
Learn Java in a day
diverse functionalities ranging from the addition of two numbers
Operators
certain tasks like addition, subtraction etc. Simple Assignment Operator = 
Operators
certain tasks like addition, subtraction etc. Simple Assignment Operator = 
What You Get Out Of Apple's New iPad
What You Get Out Of Apple’s New iPad Apple’s iPad is the newest addition to the 'i' series, following on from the iPod, iPhone and iMac. Computer users all over the world waited with bated breath for its release
Just Got An iPad? - The Range Of Protective Cases You Can Choose From
Just Got An iPad? - The Range Of Protective Cases You Can Choose From Apple’s latest addition to the “i” series, the iPad, has been making waves all around the globe, and if you have just got yourself one

Ads