Difference between (subtracting) 2 columns

N

Niek Otten

Select column C1 and down, as far as the data goes.

Type =B1-A1, hold CTRL while you press ENTER
 
S

Stephen

Lior said:
Hi .

In Excel 2003 , I want to do the following thing :

suppose we have column A with the content :

12
14
16
18
20


and column B with the content :

20
40
60
80
100


I want that column C (using a single formula) will have the content :

8
26
44
62
80

ie. column C will be column B , minus column A (corresponding to the
indexes of the cells : 20-12=8 , 40-14=26,
60-16=44,80-18=62,100-20=80) . How can I do that using a single formula
?

Thanks in advance ,
Lior .

You can't get 5 results from 1 formula. What you can do (and this may be
what you meant) is to get 5 results from 5 similar formulas.
Assuming your data are in A1:A5 and B1:B5, in C5 put the formula
=B1-A1.
Then copy this cell, select C2:C5 and paste. That will give you 5 similar
formulas because the cell references 'adjust' as they are pasted. Look at
each of the resulting formulas and you will see how this works.
 
D

Domenic

Enter the following formula in C1...

=B1-A1

Then you can either copy and paste the formula to your other cells or
you can move the cursor to lower right corner of C1, click the mouse,
and drag down the column.

Hope this helps!
 
L

Lior

Hi .

In Excel 2003 , I want to do the following thing :

suppose we have column A with the content :

12
14
16
18
20


and column B with the content :

20
40
60
80
100


I want that column C (using a single formula) will have the content :

8
26
44
62
80

ie. column C will be column B , minus column A (corresponding to the
indexes of the cells : 20-12=8 , 40-14=26,
60-16=44,80-18=62,100-20=80) . How can I do that using a single formula ?

Thanks in advance ,
Lior .
 
L

Lior

Hi , thank you all , it's OK .

Lior :)



Domenic said:
Enter the following formula in C1...

=B1-A1

Then you can either copy and paste the formula to your other cells or
you can move the cursor to lower right corner of C1, click the mouse,
and drag down the column.

Hope this helps!
 
Top