0% found this document useful (0 votes)
92 views84 pages

Get Started With Formulas: Let's Go

You can perform basic math operations like addition, subtraction, multiplication, and division in Excel without using functions by simply inputting the operators (+, -, *, /) and cell references or values. Formulas always begin with an equals sign (=) and are confirmed by pressing Enter. Excel formulas can include cell references, ranges of cells, operators, and constants to perform calculations on the data.

Uploaded by

Rizal Angga DP
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as XLS, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
92 views84 pages

Get Started With Formulas: Let's Go

You can perform basic math operations like addition, subtraction, multiplication, and division in Excel without using functions by simply inputting the operators (+, -, *, /) and cell references or values. Formulas always begin with an equals sign (=) and are confirmed by pressing Enter. Excel formulas can include cell references, ranges of cells, operators, and constants to perform calculations on the data.

Uploaded by

Rizal Angga DP
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as XLS, PDF, TXT or read online on Scribd

Let's go >

Get started with formulas


In just a few steps, you'll be up and running with building formulas and functions in Excel, the
world's most powerful spreadsheet app.

Go back to top by pressing CTRL+HOME. To start the tour, press CTRL+PAGE DOWN.
constants
aren't a good
practice. Why?
Because you
can't easily
see the
constant
without
selecting the
cell
You Basics: doing math with Excel
anddoing math with Excel
Basics:
can for
looking Add,it. Subtract, Multiply, and Divide in Excel without using any built-in functions. You just need to use some basic opera
That canselect
To Add, makecell F3, type =C3+C4, then press Enter.
it hard to
change later.You can Add, Subtract, Multiply, and Divide in Excel without using any built-in functions.
To
To Subtract,
It's muchYouselect
Multiply, select cell
cell F4, type
type =C3-C4, then press
press Enter.
just needF5, to use =C3*C4,
some basicthenoperators:
Enter.+, -, *, /. All formulas start with an equals (=)
easier to put
To Divide,sign.select cell F6, type =C3/C4, then press Enter.
your constants
in cells, where
Check
they can thisbeout: change the numbers in cells C3 and C4, and watch the formula results automatically change.

adjusted, and1
easily
EXTRA CREDIT: You can raise a value to a power by using the carat (^) symbol, like =A1^A2. Enter it with Shift+6. In cell F7, ente
Dive down for
referenced in more detail
your
Next formulas.
step
More
Excel
For made2
isabout
example:
formulas, cells, and
up of individual ranges
cells that are grouped into rows and columns. Rows are numbered, and columns are lettered. Th
Select the
yellow cell that in our third example above, we used the SUM function. A function is a pre-built command that takes a value
You'll notice
with 12 below.
Formulas
You'll see with
3
we functions start with an equals sign, then the function name follows with its arguments (the values a function us
used the SUM
function with
a range of
Some
cells. Weformula 4 explanations
=10*20type
didn't is a in
formula, where 10 and 20 are constants, and the * sign is the operator.
"4" or "8"
=SUM(A1:A10) is a formula, where SUM is the function name, the opening and closing parentheses contain the formula argum
directly into
=SUM(A1:A10,C1:C10)
the formula. is a formula, where SUM is the function name, the opening and closing parentheses contain the formul
Dive down for more detail
Previous
Next
More information on the web
More about formulas, cells, and ranges
Use Excel as a calculator
OverviewExcel
of formulas
is madeinupExcel
of individual cells that are grouped into rows and columns. Rows are
Excel functions (by category)
numbered, and columns are lettered. There are over 1 million rows and 16,000 columns,
and you can put formulas in any of them.
Excel functions (alphabetical)
Formulas
Free Excel can contain cell references, ranges of cell references, operators, and constants.
training online
The following are all examples of formulas:

=A1+B1
=10*20
=SUM(A1:A10)

You'll notice that in our third example above, we used the SUM function. A function is a
pre-built command that takes a value or values, calculates them in a certain way, and
returns a result. For instance, the SUM function takes the cell references or ranges you
specify, and totals them. In this example it takes the cells A1 through A10, and totals
them. Excel has over 400 functions, which you can explore on the Formulas tab.
Formulas with functions start with an equals sign, then the function name follows with its
arguments (the values a function uses to calculate) wrapped in parentheses.

You confirm a formula by pressing Enter. Once you do that the formula will calculate, and
the result will be displayed in the cell. To see the formula itself, you can look at the
formula bar beneath the Ribbon, or press F2 to enter Edit mode, where you'll see the
formula in the cell. Press Enter again to finalize the formula and calculate the result.

Previous

More information on the web


cs:
Basics: doing math with Excel
candoing math withMultiply,
Add, Subtract, Excel and Divide in Excel without using any built-in functions. You just need to use some basic operators: +, -, *, /. Al
Add, select cell F3, type =C3+C4, then press Enter.
You can Add, Subtract, Multiply, and Divide in Excel without using any built-in functions.
ubtract, select
Multiply, select cell
cell F5,
F4, type
type =C3-C4, then press
press Enter.
You just need to use =C3*C4, thenoperators:
some basic Enter.+, -, *, /. All formulas start with an equals (=)
Divide,sign.
select cell F6, type =C3/C4, then press Enter.

ck this out: change the numbers in cells C3 and C4, and watch the formula results automatically change.
RA CREDIT:1 YouTocanAdd,
raiseselect cell
a value toF3, type =C3+C4,
a power then
by using the press
carat Enter. like =A1^A2. Enter it with Shift+6. In cell F7, enter =C3^C4.
(^) symbol,
e down for more detail

made2
re isabout To Subtract,
formulas, cells, and select
ranges cell F4, type =C3-C4, then press Enter.
el up of individual cells that are grouped into rows and columns. Rows are numbered, and columns are lettered. There are over 1 m

ll notice that in our third example above, we used the SUM function. A function is a pre-built command that takes a value or values, calcul
3 functions
mulas with
To Multiply, select cell F5, type =C3*C4, then press Enter.
start with an equals sign, then the function name follows with its arguments (the values a function uses to calculate) w

me formula 4 explanations
To Divide, select cell F6, type =C3/C4, then press Enter.
*20 is a formula, where 10 and 20 are constants, and the * sign is the operator.
M(A1:A10) is a formula, where SUM is the function name, the opening and closing parentheses contain the formula arguments, and A1:A1
M(A1:A10,C1:C10) is a formula, where SUM is the function name, the opening and closing parentheses contain the formula arguments, an
Next step
Dive down for more detail

re information on the web


More about formulas, cells, and ranges
Excel as a calculator
rviewExcel
of formulas
is madeinupExcel
of individual cells that are grouped into rows and columns. Rows are
el functions (by category)
numbered, and columns are lettered. There are over 1 million rows and 16,000 columns,
and you can put formulas in any of them.
el functions (alphabetical)
Formulas
e Excel can contain cell references, ranges of cell references, operators, and constants.
training online
The following are all examples of formulas: =A1+B1
=A1+B1 Cell
=10*20 reference
=SUM(A1:A10)

You'll notice that in our third example above, we used the SUM function. A function is a
pre-built command that takes a value or values, calculates them in a certain way, and
returns a result. For instance, the SUM function takes the cell references or ranges you
specify, and totals them. In this example it takes the cells A1 through A10, and totals
them. Excel has over 400 functions, which you can explore on the Formulas tab. =SUM(A
Formulas with functions start with an equals sign, then the function name follows with its A range of cells has
ending cell. When y
arguments (the values a function uses to calculate) wrapped in parentheses.
formula, Excel will
You confirm a formula by pressing Enter. Once you do that the formula will calculate, and
the result will be displayed in the cell. To see the formula itself, you can look at the
formula bar beneath the Ribbon, or press F2 to enter Edit mode, where you'll see the
formula in the cell. Press Enter again to finalize the formula and calculate the result.

Previous Next
=SUM(A
More information on the web Opening p

Use Excel as a calculator

Overview of formulas in Excel

Excel functions (by category)

Excel functions (alphabetical) 

Free Excel training online


Numbers to use: Operation: Formulas: Answers:
1 Addition (+) 3
2 Subtraction (-) -1
Multiplication (*) 2
Division (/) 0.5
Power (^) 1
ft+6. In cell F7, enter =C3^C4.
EXTRA CREDIT
CHECK THIS OUT You can raise a value to
Change the numbers here, a power by using the
mns are lettered.
and There are over
watch million rows and 16,000 columns, and you carat
the1formula can put(^) symbol,
formulas like
in any of them.
results automatically =C3^C4. Enter it with
value or values, calculates them in a certain way, and returns a Shift+6.
that takes a change. result. For instance, the SUM function takes the cell references
alues a function uses to calculate) wrapped in parentheses.

the formula arguments, and A1:A10 is the cell range for the function.
contain the formula arguments, and A1:A10,C1:C10 are the cell ranges for the function separated by a comma.

GOOD TO KNOW
Operator Operator Constants are values that you enter in
formulas. While =10+20 might calcul

=A1+B1 =10*20 same as =A1+B1, constants aren't a


practice. Why? Because you can't eas
constant without selecting the cell an
it. That can make it hard to change la
Cell Cell
Constant Constant much easier to put your constants in
reference reference
they can be easily adjusted, and refer
your formulas.

For example: Select the yellow cell wi


Function Argument You'll see we used the SUM function
of cells. We didn't type in "4" or "8" d

=SUM(A1:A10) the formula.


A range of cells has a starting cell, colon, and an
ending cell. When you select a range of cells for a
formula, Excel will automatically add the colon.

Commas separate multiple arguments

Function Argument Argument

=SUM(A1:A10,C1:C10)
A range of cells Another range of cells

Opening parenthesis Closing parenthesis. Excel will usually add this


for you when you press Enter.
M function takes the cell references or ranges you specify, and totals them. In this example it takes the cells A1 through A10, and totals them

O KNOW
are values that you enter in cells or
While =10+20 might calculate the
=A1+B1, constants aren't a good
Why? Because you can't easily see the
without selecting the cell and looking for
n make it hard to change later. It's
ier to put your constants in cells, where
be easily adjusted, and referenced in
ulas.

ple: Select the yellow cell with 12 below.


we used the SUM function with a range
We didn't type in "4" or "8" directly into
la.

Values
4
8
12

ents

xcel will usually add this


you press Enter.
ugh A10, and totals them. Excel has over 400 functions, which you can explore on the Formulas tab.
or type
=SUM(, then
select that
range with the
mouse, and
press Enter.
This will sum
the values in
cells D3, D4,
D5,
Introduction to functions
and D6. to functions
Introduction
Your answer
Functions
should be give
170. you the ability to do a variety of things, like perform mathematical operations, look up values, or even
Now let's try AutoSum. Select the cell under the column for Meat (cell G7), then go to Formulas > AutoSum > select SUM. You'
Go to theFunctions
Formulasgive you browse
tab and the ability to do the
through a variety of things,
Function like
Library, perform
where mathematical
functions are listed by category, like Text, D
operations,
Here's a neat keyboardlook up values,
shortcut. Select or
celleven
D15,calculate
then pressdates
Alt =,and
thentimes.
Enter. Let's try a few ways
This automatically to SUM for you.
enters
When CREDIT
Dive
EXTRA add up values with the SUM function.
you start typing a function name after you press =, Excel will launch Intellisense, which will list all of the functio
down for more detail
Try the COUNT function using any of the methods you've already tried. The COUNT function counts the number of cells in a ran
Next step 1
More about functions
Now
If the let's
SUMlook at the
function anatomy
could of a few
talk, it would say,functions.
return theThe
sumSUM
of allfunction is in
the values structured like
cells D38 to this:
D41, and all of column H. SUM is the
2
The
CHECKTODAY
THISfunction
OUT returns today's date. It will automatically update when Excel recalculates.
Select these cells.
IMPORTANT DETAIL Then in the lower-right corner of the Excel window, look for SUM: 170 in the bottom bar. That's called the St
Double-click this cell. You'll notice the 100 toward the end. Although it's possible to put numbers in a formula like this, we don
More information on the web
All about the3SUM function
Use AutoSum to sum numbers
All about the COUNT function
Free Excel training online
Back to top
Dive down for more detail
Next step

More about functions


Go to the Formulas tab and browse through the Function Library, where functions
are listed by category, like Text, Date & Time, etc. Insert Function will let
you search for functions by name, and launch a function wizard that can help you build
your formula.

When you start typing a function name after you press =, Excel will launch Intellisense,
which will list all of the functions starting with the letters you type. When you find the one
you want, press Tab, and Excel will automatically finish the function name and enter the
opening parenthesis for you. It will also display the optional and required arguments.

Now let's look at the anatomy of a few functions. The SUM function is structured like this:
If the SUM function could talk, it would say, "Return the sum of all the values in cells D38
to D41, and all of column H".

Now, let's try one that doesn't require any arguments.

More information on the web

Back to top

Free Excel training online


Go back to top by pressing CTRL+HOME. To proceed to the next step, press CTRL+PAGE DOWN.
Introduction to functions
oduction to functions
ctions give you the ability to do a variety of things, like perform mathematical operations, look up values, or even
w let's try AutoSum. Select the cell under the column for Meat (cell G7), then go to Formulas > AutoSum > select SUM. You'll see Excel auto
to theFunctions
Formulasgive you browse
tab and the ability to do the
through a variety of things,
Function Library,like perform
where mathematical
functions are listed by category, like Text, Date & Time, etc
operations,
e's a neat keyboardlook up values,
shortcut. Select or
celleven
D15,calculate
then pressdates
Alt =,and
thentimes.
Enter. Let's try a few ways
This automatically to SUM for you.
enters
add
en CREDIT
eRA up values with the SUM function.
you start typing a function name after you press =, Excel will launch Intellisense, which will list all of the functions starting wit
down for more detail
the COUNT function using any of the methods you've already tried. The COUNT function counts the number of cells in a range that contain
1 Under the Amount column for Fruit (cell D7), enter =SUM(D3:D6), or type =SUM(,
then select that range with the mouse, and press Enter. This will sum the values in
re about functions
cells D3, D4, D5, and D6. Your answer should be 170.
we let's
SUMlook at the
function couldanatomy of a few
talk, it would say,functions.
return theThe
sumSUM
of allfunction
the valuesis in
structured like
cells D38 to this:
D41, and all of column H. SUM is the function name
2 Now let's try AutoSum. Select the yellow cell under the column for Meat (cell
CK THIS OUT G7),
TODAY function then go
returns to Formulas
today's date. It will>automatically
AutoSum > update
select SUM. You'llrecalculates.
when Excel see Excel
ct these cells.
ORTANT automatically
DETAIL enter thecorner
Then in the lower-right formula forExcel
of the you. window,
Press Enterlook to
forconfirm
SUM: 170 it. in
The
the bottom bar. That's called the Status Bar, and it's
AutoSum feature has all of the most common functions.
ble-click this cell. You'll notice the 100 toward the end. Although it's possible to put numbers in a formula like this, we don't recommend it
re information on the web
about the3SUMHere'sfunctiona neat keyboard shortcut. Select cell D15, then press then,
Alt Enter. =
This
AutoSum to sum numbersautomatically enters SUM for you.
about the COUNT function
e Excel training online
Next step
Dive down for more detail

More about functions


Go to the Formulas tab and browse through the Function Library, where functions
are listed by category, like Text, Date & Time, etc. Insert Function will let
you search for functions by name, and launch a function wizard that can help you build
your formula.

When you start typing a function name after you press =, Excel will launch Intellisense,
which will list all of the functions starting with the letters you type. When you find the one
you want, press Tab, and Excel will automatically finish the function name and enter the
opening parenthesis for you. It will also display the optional and required arguments.

Now let's look at the anatomy of a few functions. The SUM function is structured like this:

The function The first Additional


name. argument. It's arguments,
almost always separated by
required. commas (,).
The function The first Additional
name. argument. It's arguments,
almost always separated by
required. commas (,).

=SUM(D38:D41,H:H)
If the SUM function could talk, it would say, "Return the sum of all the values in cells D38
to D41, and all of column H".

Now, let's try one that doesn't require any arguments.

The TODAY function returns today's date. It will


automatically update when Excel recalculates.

=TODAY()

More information on the web


All about the SUM function

Use AutoSum to sum numbers

All about the COUNT function

Free Excel training online

Back to top
Next step

e Excel training online


back to top by pressing CTRL+HOME. To proceed to the next step, press CTRL+PAGE DOWN.
Fruit Amount Meat Amount
Apples 50 Beef 50
Oranges 20 Chicken 30
Bananas 60 Pork 10
Lemons 40 Fish 50
SUM > 170 SUM >

Item Amount Item Amount


Bread 50 Bread 50
Donuts 100 Donuts 100
Cookies 40 Cookies 40
Cakes 50 Cakes 50
Pies 20 Pies 20
SUM > COUNT >

EXTRA CREDIT
Try the COUNT function using
any of the methods you've
already tried. The COUNT
function counts the number of
cells in a range that contain
numbers.

Fruit Amount
Apples 50 CHECK THIS OUT
Oranges 20 Select these cells. Then in the lower-right
Bananas 60 corner of the Excel window, look for this:
Lemons 40
SUM > 170
That's called the Status Bar, and it's just
another way to quickly find a total and other
details about a selected cell or range.
Item Amount
Cars 20
Trucks 10
Bikes 10
Skates 40

Total: Additional Value New Total


180 100 180

IMPORTANT DETAIL
Double-click this cell. You'll notice the 100
toward the end. Although it's possible to put
numbers in a formula like this, we don't
recommend it unless it's absolutely necessary.
This is known as a constant, and it's easy to
forget that it's there. We recommend referring
to another cell instead, like cell F51. That way
it's easily seen and not hidden inside a formula.
EXTRA CREDIT
Previous
Try using Next
CHECK THIS
MEDIAN or
OUT
MODE here.
AVERAGE function
AVERAGE
Select
functionany
range of gives
MEDIAN
Use the AVERAGE
numbers, then function to get the average of numbers in a range of cells.
you the value
Select
look cell D7,the
theUse
in theinmiddle then use AutoSum
AVERAGE to to
function add anthe
get AVERAGE
average function.
of numbers in a range of cells.
Status
of the Bar
data for
Now select cell G7, and enter an AVERAGE function by typing =AVERAGE(G3:G6).
an instant
set, while
In D15,1you can use either AutoSum, or type to enter another AVERAGE function.
cell gives
Average.
MODE
the one that
occurs
Activatethe
the previous sheet
most
Go 2sheet
to the next
frequently.

Links for more information on the web


3
Select to learn all about the AVERAGE function on the web
Select to learn all about the MEDIAN function on the web
Select to learn all about the MODE function on the web
Select to learn about free Excel training on the web
Previous

More information on the web


Previous
Next

AVERAGE function
the AVERAGE function to get the average of numbers in a range of cells.
ect cellUse
D7,the
then use AutoSum
AVERAGE to to
function add anthe
get AVERAGE
average function.
of numbers in a range of cells.
w select cell G7, and enter an AVERAGE function by typing =AVERAGE(G3:G6).
ell D15,1you can
Select
usecell D7, AutoSum,
either then use AutoSum
or type totoenter
add an AVERAGE
another function.
AVERAGE function.

vate the previous sheet


Now select cell G7, and enter an AVERAGE function by typing
2
o the next sheet
=AVERAGE(G3:G6).
s for more information on the web
3 In cell
ct to learn all about theD15, you function
AVERAGE can useoneither AutoSum, or type to enter another AVERAGE
the web
function.
ct to learn all about the MEDIAN function on the web
ct to learn all about the MODE function on the web
ct to learn about free Excel training on the web
Previous Next

More information on the web


All about the AVERAGE function

All about the MEDIAN function

All about the MODE function

Free Excel training online


Fruit Amount Meat Amount
Apples 50 Beef 50 CHECK THIS OUT
Oranges 20 Chicken 30 Select any range of numbers, then
Bananas 60 Pork 10 look in the Status Bar for an
Lemons 40 Fish 50 instant Average.
AVERAGE > AVERAGE >

Item Amount Item Amount


Bread 50 Bread 50
Donuts 100 Donuts 100
Cookies 40 Cookies 40
Cakes 50 Cakes 50
Pies 20 Pies 20
AVERAGE >

EXTRA CREDIT
Try using MEDIAN or MODE here.

MEDIAN gives you the value in the


middle of the data set, while
MODE gives the one that occurs the
most frequently.

More about the SUM function


In some of the above tips, we taught you how to use the SUM function. Here are more details about it.
Cells C37 through D41 contain data with two columns: Fruit and Amount.
The formula in cell D42: =SUM(D38:D41).
If the SUM function in cell D42 could talk, it would say this: Sum up the values in cells D38, D39, D40, and D41.
Here's another way it can be used:
Cells C47 through D48 contain data with two columns: Item and Amount.

More information on the web


All about the SUM function
All about the SUMIF function
Use Excel as your calculator
Free Excel training online
Go back to top by pressing CTRL+HOME. To proceed to the next step, press CTRL+PAGE DOWN.
T
numbers, then
r for an
GOOD TO
KNOW
You can use
either MIN or
MAX with Previous
Next
multiple ranges,
or values to

MIN and MAX functions


show the
Select
greater cell D7,
orMAX
lesser
MIN
then
In celland
use
D15,the youfunctions
of
Now those values,
select cell
Use
AutoSum
can
like use
the either
MIN function to get the minumum number in a range of cells.
G7, andto enter aa
Wizard
the AutoSum add
=MIN(A1:A10,B
Use
MAX
MIN the
Wizard, function
MAX
function.
or Use
type the MIN
function function
to get to getnumber
the maximum the smallest number
in a range of cells. in a range of cells.
1:B10),
by typing or
to enter a MIN
=MAX(A1:A10,B
=MAX(D3:D6). Use the MAX function to get the largest number in a range of cells.
or
1), MAX
where B1
More
function.
information
contains a on
the web value,
threshold 1
like 10, in which
case the the MIN function
All aobut
formula would
All about
never 2
return
the aMAX function
result less than
Free Excel training online
10.

More information on the web


You can use either MIN or MAX with multiple ranges, or values to show the greater or lesser of those values, like =MIN(A1:A10,B1:B10), or

More information on the web


All about the MIN function
All about the MAX function
Use Excel as your calculator
Free Excel training online
Previous
Next

MIN and MAX functions


and MAX functions
the MIN function to get the minumum number in a range of cells.
Use
the MAX the MIN
function function
to get to getnumber
the maximum the smallest number
in a range of cells. in a range of cells.
Use the MAX function to get the largest number in a range of cells.

1 Select cell D7, then use the AutoSum Wizard to add a MIN function.

obut the MIN function


Now select cell G7, and enter a MAX function by typing =MAX(D3:D6).
2
bout the MAX function
Excel training online

3 In cell D15, you can use either the AutoSum Wizard, or type to enter a MIN or
MAX function.

More information on the web


can use either MIN or MAX with multiple ranges, or values to show the greater or lesser of those values, like =MIN(A1:A10,B1:B10), or =MAX(A1:A10,10

e information on the web


All about the MIN function
bout the MIN function
bout the MAX function
All about the MAX function
Excel as your calculator
Excel training online
Free Excel training online
Fruit Amount Meat Amount
Apples 50 Beef 50
Oranges 20 Chicken 30
Bananas 60 Pork 10
Lemons 40 Fish 50
MIN > MAX >

Item Amount Item Amount


Bread 50 Bread 50
Donuts 100 Donuts 100
Cookies 40 Cookies 40
Cakes 50 Cakes 50
Pies 20 Pies 20
MIN or MAX > 10

GOOD TO KNOW
You can use either MIN or MAX with
N(A1:A10,B1:B10), or =MAX(A1:A10,10).
multiple ranges, or values to show the
greater or lesser of those values, like
=MIN(A1:A10,B1:B10), or
=MAX(A1:A10,B1), where B1 contains a
threshold value, like 10, in which case the
formula would never return a result less
than 10.
display a
negative
number
because you
haven't
entered your
birthday yet,
you can use an GOOD TO KNOW
IF function like
You can use keyboard shortcuts to enter
Date functions
Date functions
this: Dates and Times that won't continuously
=IF(D7="","",D
Excel can give you the current date, based on your computer's regional settings. You can also add and subtract Dates.
7-D6), which change:
says,
Check"IF D7the TODAY function, which gives you Today's date. These are live, or volatile functions, so when you open your work
out
equals Excel can give you- the
Date current date, based on your computer's regional settings. You
Ctl+;
Subtract Dates - Enter
can alsoTime
nothing, then your
add and next birthday in MM/DD/YY format in cell D7, and watch Excel tell you how many days away it is by
subtract Dates.
- Ctrl+Shift+:
Add Dates
show nothing,
- Let's say you want to know what date a bill is due, or when you need to return a library book. You can add days to
otherwise
GOOD
show
Excel
TO KNOW
D7 1
minus D6". dates and times based on the number of days starting from January 1, 1900. Times are kept in fractional portions o
keeps

Time
Excel functions
can give you the current time, based on your computer's regional settings. You can also add and subtract times. For insta
In cell D25, enter =NOW(), which will give the current time, and will update each time Excel calculates. If you need to change th
2

If this formula could talk, it would say, "Take the Time Out and subtract it from the Time In, then subtract the Lunch Out/In Tim
Previous 3
Next
More information on the web
All about the TODAY function
All about the NOW function
All about the DATE function
Free Excel training online
Time functions
Excel can give you the current time, based on your computer's regional settings. You
can also add and subtract times. For instance, you might need to keep track of how
many hours an employee worked each week, and calculate their pay and overtime.

3
Previous

More information on the web


GOOD TO KNOW
You can use keyboard shortcuts to enter
Date functions
Dates and Times that won't continuously
el can give you the current date, based on your computer's regional settings. You can also add and subtract Dates.
change:
ck outExcel
the TODAY function,
can give which
you- the gives date,
current you Today's
baseddate. These
on your are live, or regional
computer's volatile functions,
settings. so when you open your workbook tomorrow,
You
Date Ctl+;
tract Dates - Enter
can also add
Time your
andnext birthday
subtract
- Ctrl+Shift+: in MM/DD/YY format in cell D7, and watch Excel tell you how many days away it is by using =D7-D6 in
Dates.
Dates - Let's say you want to know what date a bill is due, or when you need to return a library book. You can add days to a date to find ou

1 and times based on the number of days starting from January 1, 1900. Times are kept in fractional portions of a day based on
OD TO KNOW Check out the TODAY function, which gives you Today's date. These are live, or
el keeps dates volatile functions, so when you open your workbook tomorrow, it will have
tomorrow's date. Enter =TODAY() in cell D6.
el can give you the current time, based on your computer's regional settings. You can also add and subtract times. For instance, you might n
ell D25, enter =NOW(),
Subtractwhich will- Enter
give the current
nexttime, and will update eachformat
time Excel calculates.
D7, andIf you need to change the Time format,
2 Dates your birthday in MM/DD/YY in cell
watch Excel tell you how many days away it is by using =D7-D6 in cell D8.

is formula could talk, it would say, "Take the Time Out and subtract it from the Time In, then subtract the Lunch Out/In Times, then multipl
3 Add Dates - Let's say you want to know what date a bill is due, or when you need
to return a library book. You can add days to a date to find out. In cell D10, enter a
random number of days. In cell D11, we added =D6+D10 to calculate the due date
re information on the web
from today.
about the TODAY function
about the NOW function
about the DATE function
e Excel training online
Time functions
Excel can give you the current time, based on your computer's regional settings. You
can also add and subtract times. For instance, you might need to keep track of how
many hours an employee worked each week, and calculate their pay and overtime.

1 In cell D28, enter =NOW(), which will give the current time, and will update
each time Excel calculates. If you need to change the Time format, you can go
to Ctrl+1 > Number > Time > Select the format you want.

2 Add up hours between times - In cell D36 we've entered =((D35-D32)-


(D34-D33))*24, which calculates someone's start and end times, then
subracts the time they took for lunch. The *24 at the end of the formula
converts the fractional portion of the day that Excel sees into hours. You'll
need to format the cell as a Number though. To do that, go to Home >
Format > Cells (Ctrl+1) > Number > Number > 2 decimals.

3 If this formula could talk, it would say, "Take the Time Out and subtract it from
the Time In, then subtract the Lunch Out/In Times, then multiply those by 24
to convert Excel's fractional time to hours", or =((Time In - Time Out)-(Lunch
In - Lunch Out))*24.
If this formula could talk, it would say, "Take the Time Out and subtract it from
the Time In, then subtract the Lunch Out/In Times, then multiply those by 24
to convert Excel's fractional time to hours", or =((Time In - Time Out)-(Lunch
In - Lunch Out))*24.
*24 to convert Excel's
fraction of a day to hours
Time Out Lunch Out

=((D35-D32)-(D34-D33))*24

Time In Lunch In

The inner parentheses () make sure Excel calculates those


parts of the formula by themselves. The outer parentheses
make sure Excel multiplies the final inner result by 24.

Previous Next

More information on the web


All about the TODAY function

All about the NOW function

All about the DATE function

Free Excel training online


ou open your workbook tomorrow, it will have tomorrow's date. Enter =TODAY() in cell D6.
y days away it is by using =D7-D6 in cell D8.

Date functions
Today's date:
Your birthday:
Days
act times. For until your
instance, you birthday: 0 many hoursIMPORTANT
might need to keep track of how
DETAIL
an employee worked each week, and calculate their pay and over
If you don't want Excel to display a negative
number, because you haven't entered your
Grace period days:
birthday yet, you can use an IF function like
Bill due on: 12/30/99 this: =IF(D7="","",D7-D6), which says, "IF
D7 equals
e Lunch Out/In Times, then multiply those by 24 to convert Excel's fractional nothing,
time to hours", then show
or =((Time nothing,
In - Time Out)-(Lunch In - Lunch Ou
otherwise show D7 minus D6".
GOOD TO KNOW
Excel keeps dates and times based on the
number of days starting from January 1, 1900.
Times are kept in fractional portions of a day
based on minutes. So 01/01/2017 12:30 PM is
actually stored as 42736.5208. If the Time or
Date show up as numbers like that, then you
can press Ctrl+1 > Number > select a Date
or Time format.

Time functions
Current Time:

Daily Hours Worked


Time In: 8:00 AM
Lunch Out: 12:00 PM
Lunch In: 1:00 PM
Time Out: 5:00 PM
Total Hours: 8
Static Date & Time
Date: 09/27/17
Time: 8:52 AM
alculate their pay and overtime.
y a negative
tered your
unction like
ch says, "IF
thing,
Out)-(Lunch In - Lunch Out))*24.
Joining
There are Joining text from different cells
text fromtimes
many different cellswhen you want to join text that's in different cells. This example is very common, where you hav
in Excel
In cell E3, enter =D3&C3 to join the last and first names.
SmithNancy doesn't look quite right though. We need to add a comma and a space. To do that we'll use quotes to create a new
There are many times in Excel when you want to join text that's in different cells. This
To create the full name, we'll join first and last name, but use a space without a comma. In F3, enter =C3&" "&D3.
example is very common, where you have first and last names, and want to combine
Dive downthem as first
for more name, last name, or full name. Fortunately, Excel lets us do that with the
detail
Next Ampersand (&) sign, which you can enter with Shift+7.
Using text and numbers together
Look
In cellatC36, 1C28:D29.
cellsenter See"&TEXT(D28,"MM/DD/YYYY").
=C28&" how the date and times are inMM/DD/YYYY
separate cells?isYou
thecan join them
US format together
code with the & symbol
for Month/Day/Year, like you
like 09/25/2

=C28
WORTH " &2TEXT(D28,"MM/DD/YYYY")
& "EXPLORING
If you don't don't know what format code to use, you can use Ctrl+1 > Number to format any cell the way you want. Then sele
More information on the web
All about the TEXT function
Combine text and numbers
3 online
Free Excel training

Dive down for more detail

Using text and numbers together


Now we'll use the & to join text and numbers, not just text and text

Look at cells C28:D29. See how the date and times are in separate cells? You can join
them together with the & symbol like you'll see in cells C32:C33, but that doesn't look
right, does it? Unfortunately, Excel doesn't know how you want to format the numbers,
so it breaks them down to their basest format, which is the the Serial date in this case.
We need to explicity tell Excel how to format the number portion of the formula, so it
displays the way you want in the resulting text string. You can do that with the TEXT
function and a format code.

2
Previous

More information on the web


ingare
re Joining text from different cells
text fromtimes
many different cellswhen you want to join text that's in different cells. This example is very common, where you have first and last n
in Excel
ell E3, enter =D3&C3 to join the last and first names.
thNancy doesn't look quite right though. We need to add a comma and a space. To do that we'll use quotes to create a new text string. Thi
There are many times in Excel when you want to join text that's in different cells. This
reate the full name, we'll join first and last name, but use a space without a comma. In F3, enter =C3&" "&D3.
example is very common, where you have first and last names, and want to combine
e downthem as first
for more name, last name, or full name. Fortunately, Excel lets us do that with the
detail
Ampersand (&) sign, which you can enter with Shift+7.
ng text and numbers together
k atC36,
ell 1C28:D29.
cellsenter In cell
See
=C28&"
E3,how
enter
the=D3&C3 to join
date and times arethe
"&TEXT(D28,"MM/DD/YYYY").
last and cells?
inMM/DD/YYYY
separate first names.
isYou
thecan join them
US format together
code with the & symbol
for Month/Day/Year, like you'll see in cells C3
like 09/25/2017.

SmithNancy doesn't look quite right though. We need to add a comma and a
" &2TEXT(D28,"MM/DD/YYYY")
8 & "EXPLORING
RTH space. To do that we'll use quotes to create a new text string. This time, enter
ou don't don't know what format code to use, you can use Ctrl+1 > Number to format any cell the way you want. Then select the Custom o
=D3&", "&C3. The &", "& portion lets us join a comma and space with the
re information on the web
text in the cells.
about the TEXT function
mbine text and numbers
3 Toonline
e Excel training
create the full name, we'll join first and last name, but use a space without a
comma. In F3, enter =C3&" "&D3.

Next
Dive down for more detail

Using text and numbers together


Now we'll use the & to join text and numbers, not just text and text

Look at cells C28:D29. See how the date and times are in separate cells? You can join
them together with the & symbol like you'll see in cells C32:C33, but that doesn't look
right, does it? Unfortunately, Excel doesn't know how you want to format the numbers,
so it breaks them down to their basest format, which is the the Serial date in this case.
We need to explicity tell Excel how to format the number portion of the formula, so it
displays the way you want in the resulting text string. You can do that with the TEXT
function and a format code.

1 In cell C36, enter =C28&" "&TEXT(D28,"MM/DD/YYYY"). MM/DD/YYYY is


the US format code for Month/Day/Year, like 09/25/2017.

2 In cell C37, enter =C29&" "&TEXT(D29,"HH:MM AM/PM"). HH:MM AM/PM


is the US format code for Hours:Minutes AM or PM, like 1:30 PM.
In cell C37, enter =C29&" "&TEXT(D29,"HH:MM AM/PM"). HH:MM AM/PM
is the US format code for Hours:Minutes AM or PM, like 1:30 PM.

Previous Next

More information on the web


All about the TEXT function

Combine text and numbers

Free Excel training online


First Name Last Name Last Name, First Name Full Name
Nancy Smith Smith, Nancy Nancy Smith
Andy North
Jan Kotas
Mariya Jones
Steven Thorpe
Michael Neipper
Robert Zare
Yvonne McKay

ou want. Then select the Custom option. You can copy the format code that's displayed back to your formula.

Using text & numbers


Today's date: 03/23/19
Current time: 8:33 AM

Joining text & numbers


Today's date: 43547
Current time: 43547.3568132342

Formatting text & numbers


CHECK THIS OUT
Formulas, especially big ones, can sometimes
Today's date: 03/23/2019
be hard to read, but you can break up their
Current time: 08:33 AM
parts with spaces like this:

=C28 & " " & TEXT(D28,"MM/DD/YYYY")

WORTH EXPLORING
If you don't don't know what format code to use, you
can use Ctrl+1 > Number to format any cell the way
you want. Then select the Custom option. You can
WORTH EXPLORING
If you don't don't know what format code to use, you
can use Ctrl+1 > Number to format any cell the way
you want. Then select the Custom option. You can
copy the format code that's displayed back to your
formula.
you
example
In cellstart
F33, by
typing,
looking
we've enteredExcel's
at the
auto-correct,
formula in cell
=IF(E33="Yes",
Next
should
D12. We we've
findgotit
F31*SalesTax,
added anWhen IF
for
you
0), you.
started
where we
statement
it
withdoes, press to
set
In upD9
cell
calculate
Copy D9 to
Tab to enter
=IF(C12<100,"
SalesTax
enter as ait.
shipping
D10.
This
Less is The if it's
aRange
than
Named
=IF(C9="Apple
required.
answer
EXPERT here
TIP In
Named
100","Greater
with Range,
a value
",TRUE,FALSE). of
cell
should
Named
and
than F35
we beyou'll
100").
IF statements
0.0825.
The
see
IF correct
statements
FALSE,
Ranges Our
allow
entered
What
formula isit
happens
says
answer
=IF(E35="Yes",
because
you
IF
from to an aIfallow you to make logical comparisons between conditions. An IF statement generally says that if one condition i
define
statements
if you Formulas
enter
cell
TRUE. E33
SUM(D28:D29
orange
terms equals
oris not
>number
Define
Yes, then
)*1.25,0).
an
values
apple.
Name.
greater in
Now,
thanaThis if
multiply
says
single "If cell
cell
place, IFC6?statements allow you to make logical comparisons between conditions. An IF
you ever
in cellneed
100 times
F31
E35 is
andchange
to Yes,statement generally says that if one condition is true do something, otherwise do
then
SalesTax,
TRUEtake
then
reuse and
them FALSE are unlike other words in Excel formulas in that they don't need to be in quotes, and Excel will automatically c
the
your shipping
otherwise something
=IF(C3="Apple","Yes","No") else. The formulas can return text, values, or even more calculations.
sum
cost, of
throughout
youthe only a
return
Quantity
workbook. a 0. Youmore detail
Dive
have down
to do it for
column
can
in see
one in
all
place, the
of
Next
Try
tablechanging
above,
the named
and
Yes
IF
and
you
to No
statement
rangesmultiply
canin 1
in this with
it another function
IF
usestatements
cell the
E33 to seecan also force additional calculations to be performed if a certain condition is met. Here we're going to evaluate
by 1.25,
workbook
Shipping nameby
the calculation
otherwise
going to in
anywhere
change.
return
Formulas a 0".
the workbook. >
Name 2
Manager. Click
GOOD
here toTO learn KNOW
When
more. you create a formula, Excel will automatically place colored borders around any ranges referenced in the formula, and th
3
Previous
Next
More information on the web
All about the IF function
All about the IFS function
Advanced IF statements
Dive down for more detail
Free Excel training online

IF statement with another function


IF statements can also force additional calculations to be performed if a certain
condition is met. Here we're going to evaluate a cell to see if Sales Tax should be
charged, and calculate it if the condition is true.

3
3

Previous

More information on the web


IF statements
atements allow you to make logical comparisons between conditions. An IF statement generally says that if one condition is true do somet

IF statements allow you to make logical comparisons between conditions. An IF


E andstatement generally
FALSE are unlike othersays that
words if oneformulas
in Excel condition is true
in that dodon't
they something, otherwise
need to be doand Excel will automatically capitalize them. N
in quotes,
something else. The formulas can return text, values, or even more calculations.
C3="Apple","Yes","No")
e down for more detail

atements1
atement with In cell D9 enter =IF(C9="Apple",TRUE,FALSE). The correct answer is TRUE.
can another
also forcefunction
additional calculations to be performed if a certain condition is met. Here we're going to evaluate a cell to see if Sa

2 Copy D9 to D10. The answer here should be FALSE, because an orange is not
an apple.
OD TO KNOW
en you create a formula, Excel will automatically place colored borders around any ranges referenced in the formula, and the correspondin
3 Try another example by looking at the formula in cell D12. We got you started
with =IF(C12<100,"Less than 100","Greater than or equal to 100"). What
happens if you enter a number greater than or equal to
re information100 in cell
on the webC12?
about the IF function
about the IFS function
anced IF statements Next
Dive down for more detail
e Excel training online

IF statement with another function


IF statements can also force additional calculations to be performed if a certain
condition is met. Here we're going to evaluate a cell to see if Sales Tax should be
charged, and calculate it if the condition is true.

1 In cell F33, we've entered =IF(E33="Yes",F31*SalesTax,0), where we set up


SalesTax as a Named Range with a value of 0.0825. Our formula says If cell E33
equals Yes, then multiply cell F31 times SalesTax, otherwise return a 0.

Try changing Yes to No in cell E33 to see the calculation change.

2 Next we've added an IF statement to calculate shipping if it's required. In cell


F35 you'll see =IF(E35="Yes",SUM(D28:D29)*1.25,0). This says "If cell E35 is
Yes, then take the sum of the Quantity column in the table above, and multiply
it by 1.25, otherwise return a 0".

3 Next, change the 1.25 in the formula in cell F35 to "Shipping". As you start
typing, Excel's auto-correct, should find it for you. When it does, press Tab to
enter it. This is a Named Range, and we entered it from Formulas > Define
Name. Now, if you ever need to change your shipping cost, you only have to
3 Next, change the 1.25 in the formula in cell F35 to "Shipping". As you start
typing, Excel's auto-correct, should find it for you. When it does, press Tab to
enter it. This is a Named Range, and we entered it from Formulas > Define
Name. Now, if you ever need to change your shipping cost, you only have to
do it in one place, and you can use the Shipping name anywhere in the
workbook.

Previous Next

More information on the web


All about the IF function

All about the IFS function

Advanced IF statements

Free Excel training online


at if one condition is true do something, otherwise do something else. The formulas can return text, values, or even more calculations.

will automatically capitalize them. Numbers don't need to be in quotes either. Regular text, like Yes or No does need to be in quotes like thi

IF statements
Apple
Orange

50 Less than 100

the formula, and the corresponding ranges in the formula will be the same color. You can see this if you select cell F33 and press F2 to edit
IMPORTANT DETAIL
TRUE and FALSE are unlike other words in Excel
formulas in that they don't need to be in quotes,
and Excel will automatically capitalize them.
Numbers don't need to be in quotes either.
Regular text, like Yes or No does need to be in
quotes like this:
=IF(C3="Apple","Yes","No")

Item Quantity Cost Total


Widget 2 $9.76 $19.52
Doohickey 3 $3.42 $10.26

Sub-Total $13.18 $29.78

Sales Tax? Yes $2.46 GOOD TO KNOW


When you create a formula, Excel w
automatically place colored borders
Shipping? Yes $6.25
any ranges referenced in the formul
the corresponding ranges in the form
Total $38.48 be the same color. You can see this
select cell F33 and press F2 to edit
formula.

EXPERT TIP
Named Ranges allow you to define terms or values in a
single place, and then reuse them throughout a
workbook. You can see all of the named ranges in this
EXPERT TIP
Named Ranges allow you to define terms or values in a
single place, and then reuse them throughout a
workbook. You can see all of the named ranges in this
workbook by going to Formulas > Name Manager.
Click here to learn more.
or even more calculations.

es need to be in quotes like this:

ct cell F33 and press F2 to edit the formula.

KNOW
reate a formula, Excel will
ly place colored borders around
referenced in the formula, and
onding ranges in the formula will
e color. You can see this if you
33 and press F2 to edit the
exists, but you
we'll
still want
In cell wrap
D22, toour
existing
suppress
enter the
VLOOKUP
#N/A
=VLOOKUP(C2error,
formula
you can use
2,C17:D20,2,F like an
this
error in cell
ALSE).handling
The
D43:
function
correct called
IFERROR
answer for in
=IF(C43="","",
cell
ApplesG43: is 50.
VLOOKUP(C43
=IFERROR(VLO
VLOOKUP
VLOOKUP
VLOOKUP
,C37:D41,2,FA
VLOOKUP
OKUP(F43,F37
looked is one of the most widely used functions in Excel (and one of our favorites too!). VLOOKUP lets you look up a value in
Now
LSE)) tryfor
for
:G41,2,FALSE),
Apples, found
yourself in the
"").
it,
Meat IFERROR
then went
=VLOOKUP(A1,B:C,2,FALSE)
section,
This
says
over saystheif cell
ifone
in
What
C43 cell G22.
equals
dotoyouVLOOKUP is one of the most widely used functions in Excel (and one of our favorites
VLOOKUP
column
You should thewant to look for?
nothing
If
returns
youupand
right, find(""),
too!).
a valid VLOOKUP lets you
it, how many columns look
to the updo
right a value in atocolumn
you want on the left, then returns
get a value?
end
then with
return
result,
returned
Where
=VLOOKUP(F2 then
dotheinformation in another
you want to look for it? column to the right if it finds a match. VLOOKUP says:
nothing,
display
amount. that,
2,F17:G20,2,F
otherwise
Do you want an exact, or approximate match?
otherwise,
ALSE).
return
displaythe
VLOOKUP's
nothing ("").
results.
EXPERIMENT
We Note
displayed
the
Try second
nothing here different items from the drop down lists. You'll see the result cells instantly update themselves with new values.
selecting
closing
(""), but youfor more detail
Dive down
parenthesis
can also useat
Next
the end of(0,1,
numbers the
formula.
VLOOKUP
2, This
etc.), or and #N/A
Invariably,
closes the as you'll
IF run into a situation where VLOOKUP can't find what you asked it to, and it returns an error (#N/A). Sometimes
text, such
statement.
"Formula isn't
IMPORTANT DETAIL
correct".
IFERROR is what's known as a blanket error handler, meaning it will suppress any error your formula might throw. This can caus

A rule of thumb is to not add error handlers to your formulas until you're absolutely certain they work properly.
Previous
Next
More information on the web
All about the VLOOKUP function
1
All about the INDEX/MATCH functions
All about the IFERROR function
Use PivotTables to analyze worksheet data
2 online
Free Excel training

Dive down for more detail

VLOOKUP and #N/A


Invariably, you'll run into a situation where VLOOKUP can't find what you asked it to,
and it returns an error (#N/A). Sometimes, it's because the lookup value simply doesn't
exist, or it can because the reference cell doesn't have a value yet.

1
2

Previous

More information on the web


VLOOKUP
OKUP is one of the most widely used functions in Excel (and one of our favorites too!). VLOOKUP lets you look up a value in a column on th

OOKUP(A1,B:C,2,FALSE)
VLOOKUP
at do you want to is
lookone of the most widely used functions in Excel (and one of our favorites
for?
ou find it, how many columnsyou
too!). VLOOKUP lets look
to the updo
right a value in atocolumn
you want on the left, then returns
get a value?
ere doinformation in another
you want to look for it? column to the right if it finds a match. VLOOKUP says:
you want an exact, or approximate match?
What do you If you find it, how many
want to look columns to the right do
ERIMENT for? you want to get a value?
selecting different items from the drop down lists. You'll see the result cells instantly update themselves with new values.
e down for more detail

OKUP
riably, and =VLOOKUP(A1,B:C,2,FALSE)
#N/A
you'll run into a situation where VLOOKUP can't find what you asked it to, and it returns an error (#N/A). Sometimes, it's because th

ORTANT DETAIL
RROR is what's known as a blanket error handler, meaning it will suppress any error your formula might throw. This can cause problems if Ex
Where do you Do you want
want to look an exact,
le of thumb is to not add error handlers to your formulas until you're or
absolutely certain they work properly.
for it? approximate
match?

re information on the web


about the VLOOKUP function
1 In cell D22,functions
about the INDEX/MATCH
enter =VLOOKUP(C22,C17:D20,2,FALSE). The correct answer for
Apples is 50. VLOOKUP looked for Apples, found it, then went over one column
about the IFERROR function
to the right, and returned the amount.
PivotTables to analyze worksheet data
2 Now
e Excel training try for yourself in the Meat section, in cell G22. You should end up with
online
=VLOOKUP(F22,F17:G20,2,FALSE).

Next
Dive down for more detail

VLOOKUP and #N/A


Invariably, you'll run into a situation where VLOOKUP can't find what you asked it to,
and it returns an error (#N/A). Sometimes, it's because the lookup value simply doesn't
exist, or it can because the reference cell doesn't have a value yet.

1 If you know your lookup value exists, but want to hide the error if the lookup cell
is blank, you can use an IF statement. In this case, we'll wrap our existing
VLOOKUP formula like this in cell D43:

=IF(C43="","",VLOOKUP(C43,C37:D41,2,FALSE))

This says, "If cell C43 equals nothing (""), then return nothing, otherwise return
If you know your lookup value exists, but want to hide the error if the lookup cell
is blank, you can use an IF statement. In this case, we'll wrap our existing
VLOOKUP formula like this in cell D43:

=IF(C43="","",VLOOKUP(C43,C37:D41,2,FALSE))

This says, "If cell C43 equals nothing (""), then return nothing, otherwise return
the VLOOKUP's results". Note the second closing parenthesis at the end of the
formula. This closes the IF statement.

2 If you're not sure your lookup value exists, but you still want to suppress the
#N/A error, you can use an error handling function called IFERROR in cell G43:
=IFERROR(VLOOKUP(F43,F37:G41,2,FALSE),""). IFERROR says, "If the
VLOOKUP returns a valid result, then display that, otherwise, display nothing
("")". We displayed nothing here (""), but you can also use numbers (0,1, 2, etc.),
or text, such as "Formula isn't correct".

Previous Next

More information on the web


All about the VLOOKUP function

All about the INDEX/MATCH functions

All about the IFERROR function

Use PivotTables to analyze worksheet data

Free Excel training online


ou look up a value in a column on the left, then returns information in another column to the right if it finds a match. VLOOKUP says:

with new values.

(#N/A). Sometimes, it's because the lookup value simply doesn't exist, or it can because the reference cell doesn't have a value yet.

Fruit Amount Meat Amount


Apples 50 Beef 50
Oranges 20 Chicken 30
Bananas 60 Pork 10
Lemons 40 Fish 50

Apples Pork

EXPERIMENT
Try selecting different items from the drop down lists. You'll
see the result cells instantly update themselves with new
values.

M function in cell D42 could talk, it would say this: Sum up the values in cells D38, D39, D40, and D41.
Item Amount Item Amount
Bread 50 Bread 50
Donuts 100 Donuts 100
Cookies 40 Cookies 40
Cakes 50 Cakes 50
Pies 20 Pies 20
#N/A Pastry #N/A

IMPORTANT DETAIL
IFERROR is what's known as a blanket error handler,
meaning it will suppress any error your formula
might throw. This can cause problems if Excel is
giving you a notification that your formula has a
legitimate error that needs to be fixed.

A rule of thumb is to not add error handlers to your


formulas until you're absolutely certain they work
properly.
ch. VLOOKUP says:

have a value yet.


Conditional functions - SUMIF
Conditional functions - SUMIF
Conditional functions let you sum, average, count or get the min or max of a range based on a given condition, or criteri
SUMIF lets you sum in one range based on a specifc criteria you look for in another range, like how many Apples you h
Conditional functions let you sum, average, count or get the min or max of a range
=SUMIF(C3:C14,C17,D3:D4)
based on a given condition, or criteria you specify. Such as, out of all the fruits in the list,
What range do you want to look at?
how many are apples? Or, how many oranges are the Florida type?
What
EXPERT value
TIP (text or number) do you want to look for?
Each
For
SUMIFS oneismatch
each of found,
the same what range
as SUMIF, but itdolets
youyou
wantusetomultiple
sum in?criteria. So in this example, you can look for Fruit and Type, instead o
the Fruit and1
Type cells has
a=SUMIFS(H3:H14,F3:F14,F17,G3:G14,G17)
drop-down
list
What where
range youdo you want to sum?
can
This select
is the
This is the first range to look in for matches
different
second range
This is Try
fruits.
to look the criteria for the first match
it,
in for
and
matches the
watch
formulas
This is the criteria for the second match
automatically
update.
Dive down for more detail
Next step
Conditional functions - COUNTIF
COUNTIF and COUNTIFS let you count values in a range based on a criteria you specify. They're a bit different from the other IF
Select cell D17 and type =COUNTIF(C50:C61,C64). COUNTIF is structured like this:
=COUNTIF(C50:C61,C64)
What range do you want to look at?
What
COUNTIFS 2the same
valueis(text or number) do you
as SUMIF, but want
it letstoyou
look
usefor?
multiple criteria. So in this example, you can look for Fruit and Type, instead

=COUNTIFS(F50:F61,F64,G50:G61,G64)
You've already
This is the first seen
rangeSUMIF,
to countSUMIFS, COUNTIF, and COUNTIFS. Now you can try on your own with the other functions, such as
This
SUMIFis the=SUMIF(C92:C103,C106,E92:E103)
criteria for the first match
SUMIFS =SUMIFS(E92:E103,C92:C103,C106,D92:D103,D106)
This is the second range to count
AVERAGEIF =AVERAGEIF(C92:C103,C106,E92:E103)
This is criteria=AVERAGEIFS(E92:E103,C92:C103,C106,D92:D92,D106)
AVERAGEIFS for the second match
Dive down
COUNTIF for more detail
=COUNTIF(C92:C103,C106)
COUNTIFS
Next =COUNTIFS(C92:C103,C106,D92:D103,D106)
MAXIFS =MAXIFS(E92:E103,C92:C103,C10,D92:D103,D106)
More
MINIFSconditional functions
=MINIFS(E92:E103,C92:C103,C106,D92:D103,D106)

=SUMIFS(H3:H14,F3:F14,F17,G3:G14,G17)
Dive down for more detail
Next
SUMIF with a value argument
Here's an example of the SUMIF function using greater than (>) to find all values greater than a given amount:
=SUMIF(D118:D122,">50")

Sum up through
....Look some values
thesebased
cells...on this criterion:
...and if the value is greater than 50, sum it up.

NOTE: If you find you are making a lot of conditional formulas, you might find that a PivotTable is a better solution. See this Piv

Dive down for more detail


More information on the web
All about the SUMIFDive down for more detail
function
All about the SUMIFS function
All about the COUNTIF function
All about the COUNTIFS function
Conditional functions - COUNTIF
All about the AVERAGEIF function
All about the AVERAGEIFS function
All about the MINIFS function
COUNTIF and COUNTIFS let you count values in a range based on a criteria you specify.
All about the MAXIFS function
They're a bit different from the other IF and IFS functions, in that they only have a criteria
Create a drop-down list
range, and criteria. They don't evalute one range, then look in another to summarize.
Free Excel training online
Back to top
Next
1

=COUNTIFS(F50:F61,F64,G50:G61,G64)

Dive down for more detail


More conditional functions
You've already seen SUMIF, SUMIFS, COUNTIF, and COUNTIFS. Now you can try on your
own with the other functions, such as AVERAGEIF/S, MAXIFS, MINIFS. They're all
structured the same way, so once you get one formula written, you can just replace the
function name with the one you want. We've written all the functions you'll need for cell
E106, so you can copy/paste these, or try to type them yourself for practice.

SUMIF =SUMIF(C92:C103,C106,E92:E103)
SUMIFS =SUMIFS(E92:E103,C92:C103,C106,D92:D103,D106)
AVERAGEIF =AVERAGEIF(C92:C103,C106,E92:E103)
AVERAGEIFS =AVERAGEIFS(E92:E103,C92:C103,C106,D92:D92,D106)
COUNTIF =COUNTIF(C92:C103,C106)
COUNTIFS =COUNTIFS(C92:C103,C106,D92:D103,D106)
MAXIFS =MAXIFS(E92:E103,C92:C103,C10,D92:D103,D106)
MINIFS =MINIFS(E92:E103,C92:C103,C106,D92:D103,D106)

Dive down for more detail

SUMIF with a value argument


Here's an example of the SUMIF function using greater than (>) to find all values greater
than a given amount:

Sum up some
values based
on this
criterion:

=SUMIF(D118:D122,">50")

NOTE: If you find you are making a lot of conditional formulas, you might find that a
PivotTable is a better solution. See this PivotTable article for more information.

More information on the web


More information on the web

Back to top
Conditional functions - SUMIF
ditional functions - SUMIF
ditional functions let you sum, average, count or get the min or max of a range based on a given condition, or criteri
MIF lets you sum in one range based on a specifc criteria you look for in another range, like how many Apples you h
Conditional functions let you sum, average, count or get the min or max of a range
MIF(C3:C14,C17,D3:D4)
based on a given condition, or criteria you specify. Such as, out of all the fruits in the list,
at range do you want to look at?
how many are apples? Or, how many oranges are the Florida type?
at value (text or number) do you want to look for?
eachismatch
MIFS found,
the same what range
as SUMIF, but itdolets
youyou
want
usetomultiple
sum in?criteria. So in this example, you can look for Fruit and Type, instead of just by Fruit. S
1 SUMIF lets you sum in one range based on a specifc criteria you look for in
another range, like how many Apples you have. Select cell D17 and type
MIFS(H3:H14,F3:F14,F17,G3:G14,G17)
at range do you=SUMIF(C3:C14,C17,D3:D14).
want to sum? SUMIF is structured like this:
is the first range to look in for matches
is the criteria for the first matchWhat range do you For each match found, what
want to look at? range do you want to sum in?
is the criteria for the second match

=SUMIF(C3:C14,C17,D3:D4)
e down for more detail

ditional functions - COUNTIF


UNTIF and COUNTIFS let you count values inWhat a range based
value (textonoranumber)
criteria you specify. They're a bit different from the other IF and IFS functio
ct cell D17 and type =COUNTIF(C50:C61,C64). COUNTIF
do you is look
want to structured
for? like this:
UNTIF(C50:C61,C64)
at range do you want to look at?
UNTIFS 2the same
at valueis(text
SUMIFS is the same as SUMIF, but it lets you use multiple criteria. So in this
or number) do you want
as SUMIF, letsto look
usefor?
example, you but
can itlook you
for Fruit multiple criteria.
and Type, So in
instead ofthis
justexample,
by Fruit.you can cell
Select lookH17
for Fruit and Type, instead of just by Fruit
and type =SUMIFS(H3:H14,F3:F14,F17,G3:G14,G17). SUMIFS is structured
UNTIFS(F50:F61,F64,G50:G61,G64)
ve already like this: SUMIFS, COUNTIF, and COUNTIFS. Now you can try on your own with the other functions, such as AVERAGEIF/S, M
is the first seen
rangeSUMIF,
to count
is the=SUMIF(C92:C103,C106,E92:E103)
MIF criteria for the firstWhat
matchrange This is the This is the
MIFS =SUMIFS(E92:E103,C92:C103,C106,D92:D103,D106)
is the second range to count do you want criteria for the criteria for the
RAGEIF =AVERAGEIF(C92:C103,C106,E92:E103)
to sum? first match second match
is criteria=AVERAGEIFS(E92:E103,C92:C103,C106,D92:D92,D106)
RAGEIFS for the second match
e down for=COUNTIF(C92:C103,C106)
UNTIF more detail
UNTIFS =COUNTIFS(C92:C103,C106,D92:D103,D106)
XIFS =MAXIFS(E92:E103,C92:C103,C10,D92:D103,D106)
re conditional
NIFS functions
=MINIFS(E92:E103,C92:C103,C106,D92:D103,D106)

=SUMIFS(H3:H14,F3:F14,F17,G3:G14,G17)
e down for more detail

MIF with a value argument


e's This is than
an example of the SUMIF function using greater the (>) to find all valuesThis is thethan a given amount:
greater
MIF(D118:D122,">50")
first range to second range
look in for to look in for
mook
up through
some values
thesebased
cells...on this criterion: matches matches
nd if the value is greater than 50, sum it up.

TE: If you find you are making a lot of conditional formulas, you might find that a PivotTable is a better solution. See this PivotTable article fo
Next
Dive down for more detail
re information on the web Next
about the SUMIFDive down for more detail
function
about the SUMIFS function
about the COUNTIF function
about the COUNTIFS function
Conditional functions - COUNTIF
about the AVERAGEIF function
about the AVERAGEIFS function
about the MINIFS function
COUNTIF and COUNTIFS let you count values in a range based on a criteria you specify.
about the MAXIFS function
They're a bit different from the other IF and IFS functions, in that they only have a criteria
ate a drop-down list
range, and criteria. They don't evalute one range, then look in another to summarize.
e Excel training online

1 Select cell D64 and type =COUNTIF(C50:C61,C64). COUNTIF is structured like


this:
What range do you
want to look at?

=COUNTIF(C50:C61,C64)

What value (text or number)


do you want to look for?

2 COUNTIFS is the same as SUMIF, but it lets you use multiple criteria. So in this
example, you can look for Fruit and Type, instead of just by Fruit. Select cell H17
and type =COUNTIFS(F50:F61,F64,G50:G61,G64). COUNTIFS is structured
like this:

This is the first This is the


range to count second range
to count

=COUNTIFS(F50:F61,F64,G50:G61,G64)

This is the This is criteria for


criteria for the the second match
first match

Dive down for more detail Next


More conditional functions
You've already seen SUMIF, SUMIFS, COUNTIF, and COUNTIFS. Now you can try on your
own with the other functions, such as AVERAGEIF/S, MAXIFS, MINIFS. They're all
structured the same way, so once you get one formula written, you can just replace the
function name with the one you want. We've written all the functions you'll need for cell
E106, so you can copy/paste these, or try to type them yourself for practice.

SUMIF =SUMIF(C92:C103,C106,E92:E103)
SUMIFS =SUMIFS(E92:E103,C92:C103,C106,D92:D103,D106)
AVERAGEIF =AVERAGEIF(C92:C103,C106,E92:E103)
AVERAGEIFS =AVERAGEIFS(E92:E103,C92:C103,C106,D92:D92,D106)
COUNTIF =COUNTIF(C92:C103,C106)
COUNTIFS =COUNTIFS(C92:C103,C106,D92:D103,D106)
MAXIFS =MAXIFS(E92:E103,C92:C103,C10,D92:D103,D106)
MINIFS =MINIFS(E92:E103,C92:C103,C106,D92:D103,D106)

Dive down for more detail Next

SUMIF with a value argument


Here's an example of the SUMIF function using greater than (>) to find all values greater
than a given amount:

Sum up some ....Look through ...and if the


values based these cells... value is
on this greater than
criterion: 50, sum it up.

=SUMIF(D118:D122,">50")

NOTE: If you find you are making a lot of conditional formulas, you might find that a
PivotTable is a better solution. See this PivotTable article for more information.

More information on the web


More information on the web
All about the SUMIF function All about the SUMIFS function

All about the COUNTIF function All about the COUNTIFS function

All about the AVERAGEIF function All about the AVERAGEIFS function

All about the MINIFS function All about the MAXIFS function

Create a drop-down list Free Excel training online

Back to top
Next step
Fruit Amount Fruit Type Amount
Apples 50 Apples Fuji 50
Oranges 20 Oranges Florida 20
Bananas 60 Bananas Cavendish 60
Lemons 40 Lemons Rough 40
Apples 50 Apples Honeycrisp 50
Oranges 20 Oranges Navel 20
Bananas 60 Bananas Lady Finger 60
Lemons 40 Lemons Eureka 40
Apples 50 Apples Honeycrisp 50
Oranges 20 Oranges Navel 20
Bananas 60 Bananas Cavendish 60
Lemons 40 Lemons Eureka 40

Fruit SUMIF Fruit Type SUMIFS


Apples Oranges Florida

nt from the other IF and IFS functions, in that they only have a criteria range, and criteria. They don't evalute
EXPERT TIP one range, then look in anoth
Each one of the Fruit and Type cells has a
drop-down list where you can select
different fruits. Try it, and watch the
formulasCOUNTIFS
uit and Type, instead of just by Fruit. Select cell H17 and type =COUNTIFS(F50:F61,F64,G50:G61,G64). automatically update. like this:
is structured

functions, such as AVERAGEIF/S, MAXIFS, MINIFS. They're all structured the same way, so once you get one formula written, you can just r

olution. See this PivotTable article for more information.


Fruit Amount Fruit Type Amount
Apples 50 Apples Fuji 50
Oranges 20 Oranges Florida 20
Bananas 60 Bananas Cavendish 60
Lemons 40 Lemons Rough 40
Apples 50 Apples Honeycrisp 50
Oranges 20 Oranges Navel 20
Bananas 60 Bananas Lady Finger 60
Lemons 40 Lemons Eureka 40
Apples 50 Apples Honeycrisp 50
Oranges 20 Oranges Navel 20
Bananas 60 Bananas Cavendish 60
Lemons 40 Lemons Eureka 40

Fruit COUNTIF Fruit Type COUNTIFS


Apples 3 Oranges Florida 1
Fruit Type Amount
Apples Fuji 50
Oranges Florida 20
Bananas Cavendish 60
Lemons Rough 40
Apples Honeycrisp 50
Oranges Navel 20
Bananas Lady Finger 60
Lemons Eureka 40
Apples Honeycrisp 50
Oranges Navel 20
Bananas Cavendish 60
Lemons Eureka 40

Fruit Type Try it


Lemons Eureka 80

Item Amount
Bread 50
Donuts 100
Cookies 40
Cakes 50
Pies 20
200
e range, then look in another to summarize.
uit and Type cells has a
ere you can select
it, and watch the
cally update. like this:
is structured

mula written, you can just replace the function name with the one you want. We've written all the functions you'll need for cell E106, so you
u'll need for cell E106, so you can copy/paste these, or try to type them yourself for practice.
GOOD TO KNOW
Double-click this cell and you'll see that the
formula is different. Specifically, the sum
criteria is ">=50" which means greater than
or equal to 50. There are other operators
you can use like "<=50" which is less than
or equal to 50. And there's "<>50" which is
not equals 50.
athefunction
criteriabox,
for
and
eachpress GO.
argument
When
is listedyou see
at the
VLOOKUP
bottom
GOOD TO of the
highlighted,
form. Press
KNOW
click
OKyou
As OKenter
when at the
bottom.
you're done,
each When
you
and select
Excel
argument's a
will
function
enter
section, thethethe
in
CHECK
list, THIS
Excel will
Let
formula
OUTyou
display
you. Let the Function Wizard guide you
theknow
argument's
If
description
You
syntax.
Function
for
its
should
Wizard
the name
will
ofguide you you want, but you're not sure how to build it, you can use the Function Wizard to help yo
the function
be displayed
end up with
toward
=VLOOKUP(C1the
bottom ofIfthe
0,C5:D8,2,FALS you know the name of the function you want, but you're not sure how to build it,
form, above
E)
GOOD TO you
the Formula KNOW can use the Function Wizard to help you out.
You
result.can type cell and range references, or select them with your mouse.
1
Previous
Next
More information on the web
Overview of formulas in Excel
2 (by category)
Excel functions
Excel functions (alphabetical)
Free Excel training online

Previous

More information on the web


Let the Function Wizard guide you
uheknow
Function Wizard
the name ofguide you you want, but you're not sure how to build it, you can use the Function Wizard to help you out.
the function

If you know the name of the function you want, but you're not sure how to build it,
OD TO you
KNOWcan use the Function Wizard to help you out.
can type cell and range references, or select them with your mouse.
1 Select cell D10, then go to Formulas > Insert Function > type
VLOOKUP in the Search for a function box, and press GO.
When you see VLOOKUP highlighted, click OK at the bottom.
When you select a function in the list, Excel will display its syntax.
e information on the web
rview of formulas in Excel
2 (byNext,
l functions enter the function arguments in their respective text boxes. As you enter
category)
l functions (alphabetical)Excel will evaluate it, and show you its result, with the final result at
each one,
Excel trainingthe bottom. Press OK when you're done, and Excel will enter the formula for
online
you.

GOOD TO KNOW
As you enter each a
argument's descrip
bottom of the form

Previous Next

More information on the web


Overview of formulas in Excel

Excel functions (by category)


Excel functions (alphabetical)

Free Excel training online


n Wizard to help you out.

Fruit Amount
Apples 50
Oranges 20
Bananas 60
Lemons 40

Apples 50

CHECK THIS OUT


You should end up with
=VLOOKUP(C10,C5:D8,2,FALSE)

GOOD TO KNOW
You can type cell and range references, or
select them with your mouse.

GOOD TO KNOW
As you enter each argument's section, the
argument's description will be displayed toward the
bottom of the form, above the Formula result.
GOOD TO
Fixing
KNOW
At some
Clicking Fixing formula errors
formula errors
point in time, you'll run across a formula that has an error, which Excel will display with #ErrorName. Errors can be hel
Error checking
Options will let - Go to Formulas > Error Checking. This will load a dialog that will tell you the general cause for your specific erro
If you
you setclick
theHelp on this Error, a help topic specific to the error message will open. If you click Show Calculation Steps, an Evalua
rules At
Each timewhen
for yousome point in time,
click Evaluate, Excel you'll run
will step acrossthe
through a formula
formula that has an at
one section error, which
a time. Excelnecessarily
It won't will tell you why an erro
display with #ErrorName. Errors can be helpful, because they point out when
errors in Excel
EXPERIMENT
are displayed
What's something's
wrong not
here? Hint: working
We're tryingright, butup
to SUM they canitems.
all the be challenging to fix. Fortunately, there are
or ignored.
several options that can help you track down the source of the error, and fix it.
Previous
Next 1
More information on the web
Detect errors in formulas
How to avoid broken formulas
Evaluate a nested formula one step at a time
Free Excel training online

3
3

Previous

More information on the web


ng
ome Fixing formula errors
formula errors
point in time, you'll run across a formula that has an error, which Excel will display with #ErrorName. Errors can be helpful, because th
r checking - Go to Formulas > Error Checking. This will load a dialog that will tell you the general cause for your specific error. In cell D9, the
u click Help on this Error, a help topic specific to the error message will open. If you click Show Calculation Steps, an Evaluate Formula dialo
h time At
yousome point in time,
click Evaluate, Excel you'll run
will step acrossthe
through a formula
formula that has an at
one section error, which
a time. Excelnecessarily
It won't will tell you why an error occurs, but it w
display with #ErrorName. Errors can be helpful, because they point out when
ERIMENT
something's
at's wrong not
here? Hint: working
We're tryingright, butup
to SUM they canitems.
all the be challenging to fix. Fortunately, there are
several options that can help you track down the source of the error, and fix it.

1 Error checking - Go to Formulas > Error Checking. This will load a dialog that
will tell you the general cause for your specific error. In cell D9, the #N/A error
e information isoncaused
the webbecause there is no value matching "Apple". You can fix this by using
ect errors in formulas
a value that does exist, suppress the error with IFERROR, or ignore it and know
w to avoid broken formulas
it will go away when you do use a value that exists.
uate a nested formula one step at a time
Excel training online

2 If you click Help on this Error, a help topic specific to the error message will
open. If you click Show Calculation Steps, an Evaluate Formula dialog will
load.

3 Each time you click Evaluate, Excel will step through the formula one section at
a time. It won't necessarily tell you why an error occurs, but it will point out
where. From there, look at the help topic to deduce what went wrong with your
formula.
3 Each time you click Evaluate, Excel will step through the formula one section at
a time. It won't necessarily tell you why an error occurs, but it will point out
where. From there, look at the help topic to deduce what went wrong with your
formula.

Previous Next

More information on the web


Detect errors in formulas

How to avoid broken formulas

Evaluate a nested formula one step at a time

Free Excel training online


e. Errors can be helpful, because they point out when something's not working right, but they can be challenging to fix. Fortunately, there a

Fruit Amount
Apples 50
Oranges 20
Bananas 60
Lemons 40

Apple #N/A

GOOD TO KNOW
Clicking Options will let you set
the rules for when errors in
Excel are displayed or ignored.

Fruit Amount
Apples 50
Oranges 20
Bananas 60
Lemons 40

Total #MACRO?

EXPERIMENT
What's wrong here? Hint: We're trying to SUM
up all the items.
What's wrong here? Hint: We're trying to SUM
up all the items.
ging to fix. Fortunately, there are several options that can help you track down the source of the error, and fix it.
More questions about Excel?
Press ALT+Q and type what you want to know.
Keep going. There is more to learn with Excel:
LinkedIn Learning: Video courses for all levels—from beginner to advanced. Take at your own pace.
Community: Ask questions and connect with other Excel fans.
What else is new?Office 365 subscribers get continual updates and new features.
Give us feedback on this tour
More questions about Excel?

More questions about Excel?


Press ALT+Q and type what you want to know.
Keep going. There is more to learn with Excel:
LinkedIn Learning: Video courses for all levels—from beginner to advanced. Take at your own pace.
Community: Ask questions and connect with other Excel fans.

Give us feedback on this tour


Click the Tell Me button and type what you want to know.

Keep going. There is more to learn with Excel:

LinkedIn Learning Community


Video courses for all levels— Ask questions and
from beginner to advanced. connect with other
Take at your own pace. Excel fans.

Learn more Learn more

Give us feedb
w.

What else is new?


Office 365 subscribers get
continual updates and
new features.

Learn more

ive us feedback on this tour

You might also like