• Home
• /
• Blog
• /
• Addition and Subtraction of Integers

# Addition and Subtraction of Integers

July 22, 2022 This post is also available in: हिन्दी (Hindi)

Addition, subtraction, multiplication, and division are four basic arithmetic operations in Math. Among these addition and subtraction is the base of the other two.

Students find it confusing especially when performing these operations with integers. In this article, you will learn the basic rules of addition and subtraction of integers along with an easy way to understand and remember these operations.

## Addition and Subtraction of Integers

Remembering the basic rules of addition and subtraction of integers and using them properly while performing the operations will definitely make the process easier and less time-consuming.

### Rules to Add and Subtract

Integers are a special group of numbers that are positive, negative, and zero, which are not fractions. Rules for addition and subtraction are the same for all.

### Negative Sign and Positive Sign

The integers which we add or subtract could be positive or negative.  Hence, it is necessary to know the rules for positive and negative symbols.

• Positive sign/symbol: (+)
• Negative sign/symbol: (-)

The three main possibilities in the addition of integers are:

• Adding two positive numbers: Add the numbers without considering the signs, and the result is positive.
• Adding two negative numbers: Add the numbers without considering the signs, and the result is negative.
• Adding a positive number and a negative number: Subtract the smaller number from the bigger number without considering the sign
• When the larger number(absolute value) is positive: The result is positive
• When the larger number(absolute value) is negative: The result is negative

Note: The number obtained after discarding the sign is called an absolute value.

For example, the absolute value of +65 is 65 and the absolute value of -65 is 65.

The above rules are summarized as:

From the above table, we can conclude that:

• Adding two positive integers results in a positive integer
• Adding two negative integers results in a sum of integers with a negative sign.
• The addition of a positive and a negative integer gives either a positive or negative-sum depending on the value of the given numbers.
• The result is positive when the greater number (absolute) is positive
• The result is negative when the greater number (absolute) is negative

An important point to remember: The sum of an integer and its opposite is always zero. (For example, -7 + 7 = 0, 7 + (-7) = 0)

### Addition of Integers – Examples

Ex 1: Add -32 and -45

(-32) + (-45)

Both -32 and -45 have a ‘-‘ sign, therefore, rule to follow:

• Negative + Negative: Operation is Add and Result is Negative

32 + 45 = 77

Therefore, -32 + (-45) = -77

Ex 2: Add 42 and -33

42 + (-33)

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is positive, so the result is positive

42 – 33 = 9

Therefore, 42 + (-33) = 9 (+9)

Ex 3: Add 57 and – 89

57 + (-89)

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is negative, so the result is negative

89 – 57 = 32

Therefore, 57 + (-89) = -32

Ex 4: Add 19 and 76

19 + 76

Both -32 and -45 have a ‘-‘ sign, therefore, the rule to follow:

• Positive + Positive: Operation is Add and Result is Positive

19 + 76 = 95

## Subtraction of Integers

In subtraction of integers also there can be three possibilities.

• Subtracting two positive numbers
• Subtracting two negative numbers
• Subtracting a positive number and a negative number

In each case, the first step is to convert the subtraction problem into an addition problem and then use an appropriate addition rule discussed above.

For ease of calculation, we need to renovate subtraction problems the addition problems. There are two steps to perform addition:

• Convert the subtraction problem into an addition problem

The following examples explain the process of conversion of subtraction problem to addition problem:

• 12 – 5 = 12 + (-5)
• 5 – 12 = 5 + (-12)
• -12 – 5 = -12 + (-5)

### Subtraction of Integers – Examples

Ex 1: 96 – 65

Convert to addition problem: 96 + (-65)

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is positive, so the result is positive

96 – 65 = 31

Ex 2: 52 – 84

Convert to addition problem: 52 + (-84)

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is negative, so the result is negative

84 – 52 = 32

Therefore, 52 – 84 = -32

Ex 3: -32 – 64

Convert to addition problem: -32 + (-64)

Both -32 and -64 have a ‘-‘ sign, therefore, rule to follow:

• Negative + Negative: Operation is Add and Result is Negative

32 + 64 = 96

Therefore, -32 – 64 = -96

Ex 4: 56 – (-32)

Convert to addition problem: 56 + 32

56 + 32 = 88

Therefore, 56 – (-32) = 88

Ex 5: -18 – (-64)

Convert to addition problem: -18 + 64

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is positive, so the result is positive

64 – 18 = 46

Therefore, -18 – (-64) = 46

## When ‘From’ is Present in Subtraction Problems

Many times subtraction problems are worded with the phrase ‘from’. For example

• Subtract 16 from 18: It becomes 18 – 16 = 2
• Subtract 18 from 16: It becomes 16 – 18 = -2
• Subtract -16 from -18: It becomes -18 – (-16) = -18 + 16 = -2
• Subtract -18 from -16: It becomes -16 – (-18) = –16 + 18 = 2
• Subtract 16 from -18: It becomes -18 – 16 = -24
• Subtract -18 from 16: It becomes 16 – (-18) = 16 + 18 = 24
• Subtract -16 from 18: It becomes 18 – (-16) = 18 + 16 = 24
• Subtract 18 from -16: It becomes -16 – 18 = -24

Note: The number that comes after ‘from’ is written first in subtract operation.

Note: While removing the bracket, remember the following rules

• +(+) = +
• +(-) = –
• -(+) = –
• -(-) = +

### Subtraction of Integers – Examples

Ex 1: Subtract 12 from 73

The number after ‘from’ is 73, so, 73 – 12

73 – 12 = 61

Therefore, the result when 12 is subtracted from 73 is 61

Ex 2: Subtract -45 from 67

The number after ‘from’ is 67, so 67 – (-45)

Convert to addition problem: 67 + 45

67 + 45 = 112

Therefore, the result when -45 is subtracted from 67 is 112

Ex 3: Subtract 58 from -23

The number after ‘from’ is -23, so -23 – 58

Convert to addition problem: -23 + (-58)

Both -32 and -45 have a ‘-‘ sign, therefore, the rule to follow:

• Negative + Negative: Operation is Add and Result is Negative

23 + 58 = 81

Therefore, -23 + (-58) = -81

And, hence the result when 58 is subtracted from -23 is -81

Ex 4: Subtract -25 from -68

The number after ‘from’ is -68, so -68 – (-25)

Convert to addition problem: -68 + 25

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is negative, so the result is negative

68 – 25 = 43

Therefore, -68 + 25 = -43

And, hence the result when -25 is subtracted from -68 is -43

Ex 5: Subtract -85 from -43

The number after ‘from’ is -43, so -43 – (-85)

Convert to addition problem: -43 + 85

Rule to follow:

• One is positive and the other is negative, so subtract
• The larger number is positive, so the result is positive

85 – 43 = 42

Therefore, -43 + 85 = 42

And, hence the result when -85 is subtracted from -43 is 42

## Addition and Subtraction of Integers Using Number Line

Before performing addition or subtraction on integers using a number line, remember these key points:

• Always start from “0”.
• Move to the right side, if the number is positive.
• Move to the left side, if the number is negative.

### Addition of Integers Using Number Line

Adding integers on a number line is done by looking at the sign of the second addend. If we add a positive number to the given integer, we move towards the right side, and if we add a negative integer to the given integer, we move towards the left side. Let us take a few examples to add integers on a number line.

Let’s consider the following examples to understand the process:

Ex 1: 4 + 5

4 + 5 = 9

Ex 2: 4 + (-5)

4 + (-5) = -1

Ex 3: -4 + 5

-4 + 5 = 1

Ex 4: -4 + (-5)

-4 + (-5) = -9

### Subtraction of Integers using Number Line

Subtracting integers on a number line is done by looking at the sign of the subtrahend. To subtract a positive integer, we move towards the left on a number line, and to subtract a negative integer we move towards the right on the number line. Let us take a few examples to subtract integers on a number line.

Ex 1: Subtract 4 from 5 means 5 – 4

Convert to addition problem: 5 + (-4)

5 – 4 = 1

Ex 2: Subtract 5 from 4 means 4 – 5

Convert to addition problem: 4 + (-5)

4 – 5 = -1

Ex 3: Subtract -4 from 5 means 5 – (-4)

Convert to addition problem: 5 + 4

5 – (-4) = 9

Ex 4: Subtract 5 from -4 means -4 – 5

Convert to addition problem: -4 + (-5)

-4 -5 = -9

Ex 5: Subtract -5 from 4 means 4 – (-5)

Convert to addition problem: 4 + 5

4 – (-5) = 9

Ex 6: Subtract 4 from -5 means -5 – 4

Convert to addition problem: -5 + (-4)

Ex 7: Subtract -4 from -5 means -5 – (-4)

Convert to addition problem: -5 + 4

-5 – (-4) = -1

Ex 8: Subtract -5 from -4 means -4 – (-5)

Convert to addition problem: -4 + 5

-4 – (-5) = 1

## Let’s Code With Python

Display rule for addition of two integers

#Addition Rules for Integers

#1. Adding two positive integers results in a positive integer
#2. Adding two negative integers results in a sum of integers with a negative sign.
#3. The addition of a positive and a negative integer gives either a positive or negative-sum depending on the value of the given numbers.
#3a. The result is positive when the greater number (absolute) is positive
#3b. The result is negative when the greater number (absolute) is negative

import math

#Accept input
x = int(input('Enter first integer: '))
y = int(input('Enter first integer: '))
sign = ''
#Display Rules
if x > 0 and y > 0:
print('Result is sum of absolute values of ', x, 'and', y, 'and sign is positive')
elif x < 0 and y < 0:
print('Result is sum of absolute values of ', x, 'and', y, 'and sign is negative')
elif (x < 0 and y > 0) or (x > 0 and y < 0):
if abs(x) > abs(y):
if math.copysign(1,x) == 1:
sign = 'positive'
elif math.copysign(1,x) == -1:
sign = 'negative'
print('Result is difference of absolute values of', x, 'and', y, 'and sign is', sign)
else:
if abs(x) < abs(y):
if math.copysign(1,y) == 1:
sign = 'positive'
elif math.copysign(1,y) == -1:
sign = 'negative'
print('Result is difference of absolute values of', x, 'and', y, 'and sign is', sign)

## Conclusion

The addition and subtraction of integers may be confusing in the beginning. But if you remember the rules discussed in the article, you’ll find it much easier to perform these operations.

## Practice Problems

Solve the following: