Given two numbers num1 and num2. The task is to write a Python program to find the addition of these two numbers.
Input: num1 = 5, num2 = 3 Output: 8 Input: num1 = 13, num2 = 6 Output: 19
In the below program to add two numbers, the user is first asked to enter two numbers and the input is scanned using the input() function and stored in the variables number1 and number2. Then, the variables number1 and number2 are added using the arithmetic operator + and the result is stored in the variable sum.
Below is the Python program to add two numbers:
Sum of 15 and 12 is 27
Example 2: Adding two number provided by user input
First number: 13.5 Second number: 1.54 The sum of 13.5 and 1.54 is 15.04
- Program to Add Two Complex Numbers
- Python program to add two Matrices
- Python program to add two matrices
- 8 different ways to Add Two Numbers in C/C++
- C Program to Add two Integers
- Java Program to Add two Matrices
- Python | Add comma between numbers
- Extract numbers from a text file and add them using Python
- Python - Add space between Numbers and Alphabets in String
- Python Program to Split the array and add the first part to the end
- Count ways to divide C in two parts and add to A and B to make A strictly greater than B
- Add, subtract, multiple and divide two Pandas Series
- Python Program for GCD of more than two (or array) numbers
- Python Program for Common Divisors of Two Numbers
- Python Program to swap two numbers without using third variable
- Python Program to find the Quotient and Remainder of two numbers
- Python | Add Logging to a Python Script
- Python | Add Logging to Python Libraries
- C Program to Swap two Numbers
- Program to find GCD or HCF of two numbers
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.