The task is to Add two number using ‘-‘ operator.
Input : 2 3 Output : 5 Input : 10 20 Output : 30
The idea is simple, we subtract -b from a.
- Number formed after K times repeated addition of smallest divisor of N
- Program for addition of two matrices
- dot (.) operator in C/C++
- array::operator[ ] in C++ STL
- Operator Overloading in C++
- sizeof operator in C
- Division without using '/' operator
- Conditional or Ternary Operator (?:) in C/C++
- typeid operator in C++ with Examples
- C++ | Nested Ternary Operator
- Operator Precedence and Associativity in C
- Modulo Operator (%) in C/C++ with Examples
- Types of Operator Overloading in C++
- Operator Functions in Python | Set 1
- Ternary Operator in Python
- Can we use % operator on floating point numbers?
- Increment (++) and Decrement (--) operator overloading in C++
- Implement *, - and / operations using only + arithmetic operator
- C++ Program to concatenate two strings using Operator Overloading
- Find the remainder when N is divided by 4 using Bitwise AND operator
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. 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.