Due: Tuesday, March 31 (8:00pm)
On the course website
Arithmetic Functions
Lookup Functions
The MATCH function searches for a specified item in a range of cells, and then returns the relative position of that item in the range.
INDEX returns the value of an element in a table or an array, selected by the row and column number indexes.
=MATCH(lookup_value, lookup_array, [match_type])
=MATCH(23, B6:B8, 0)
| A | B | |
|---|---|---|
| 6 | Red | 18 |
| 7 | Yellow | 23 |
| 8 | Blue | 7 |
=MATCH(23, B6:B8, 0) ==> 2
=INDEX(array, row_num, [column_num]) =INDEX(A6:A8, 2, 1)
| A | B | |
|---|---|---|
| 6 | Red | 18 |
| 7 | Yellow | 23 |
| 8 | Blue | 7 |
=INDEX(A6:A8, 2, 1) ==> "Yellow"
=MATCH(23, B6:B8, 0) =INDEX(A6:A8, 2, 1)
=INDEX(A6:A8, MATCH(23, B6:B8, 0), 1)
Use the VLOOKUP function to search the first column of a range of cells, and then return a value from any cell on the same row of the range.
=VLOOKUP(lookup_value,
table_array,
col_index_num,
[range_lookup])