In-Class Exercise: Lookups, Match, and IF Functions
We will practice using Lookups, Match, and IF functions in several real-world scenarios. For this exercise, open the in-class workbook, make a copy, and follow the instructions. You can find the in-class workbook here: (Starter-Workbook)-Class-Lookups-Match-IF.xlsx
Be sure to rename it something like “(Your-Name)-Class-Lookups-Match-IF”.
In this workbook, there are 5 sheets.
- Project Budget - Used for Exercise 1.
- Materials - Data used for Exercise 1.
- Employee Work Hours - Used for Exercise 2.
- Concrete Price Estimator - Used for Exercise 3.
- School Left - Used for Exercise 4.
Exercise 1 - Material Cost & Availability
This sheet contains two tables: one with material costs and one with material availability. We will use the VLOOKUP functions to find the correct unit cost and available quantities for each material in the Project Budget sheet. We will also use Data Validation to ensure that the material names are correct and that the material quantities are positive numbers.
-
Navigate to the Project Budget sheet
-
In column D, use the VLOOKUP function to find the correct unit cost for each row from the table in the Materials sheet
-
In column E, multiply the material quantities and unit costs to get the total price for each row
-
Look at the SUMIF() formula in the cells in column H. This finds the total materials used in column C for each material type (This formula is already done for you).
-
In column I, use the VLOOKUP function to find the available quantities for material from the table in the Materials sheet
-
In column J, use the difference in columns H and I to find the remaining material quantities. Note that we have conditional formatting on to highlight items that are out of stock
Exercise 2 - Employee Work Hours
This sheet contains hours worked each month for a set of employees. Our objective is a combination of VLOOKUP and MATCH to find numbers in this table.
-
Note the layout of the table on the top. Each row represents a month and each column represents an employee. The numbers are hours worked each month by the employee
-
In the table below, use the VLOOKUP to find the hours worked in the month specified in column B. Embed the MATCH function inside the VLOOKUP function to determine what column to use based on the employee name in column C. Enter your formula in D20:D33
-
Add a function in D35 to compute the total hours worked on this project
Exercise 3 - Concrete Price Estimator
The following exercise is based on the IF/IFS statements we have just covered.
-
Navigate to the Concrete Price Estimator sheet
-
Solve for the total cubic volume (cell E16)
-
Write an IFS statement in E18 to give the price per cubic foot based on the volume
-
Solve for the total price (cell E19)
-
Try adjusting the lengths of the concrete to see if it changes the price per cubic foot and total price correctly
Exercise 4 - Number of School Years Left
Use IF statements and user inputs/selections to determine how many years that the user has left to finish school. Keep in mind, this is probably not correct.
Instructions
-
Navigate to the School Left sheet
-
Fill in the criteria in the yellow cells (C9, C11, C13, C15, F17, C19). These cells have a dropdown menu to select from. You can select the cell and then click on the arrow that appears to the right of the cell to see the dropdown menu. (This is made using Data Validation, which we will cover next class)
-
Write an IF/IFS function under Years (Column I) that is dependent on the criteria and conditions given in column J.
-
Add up the total in I23 to determine how many years of school you have left.
Turning in/Rubric
REMINDER - For this class, you will only turn in the links to your Excel files. You will get a 0 for this assignment if you turn in an Excel file or a link that is not shareable.
- On the top right, click the share button --> share --> settings
- Click "anyone" at the top, then underneath "More settings", change "can view" to "can edit". Then click apply.
- Copy the link, then turn it into Learning Suite in the feedback box for that assignment.
Rubric:
| Item | Points Possible |
|---|---|
Total |
5 |
The following is not a part of the rubric, but specifies how you can lose points. For example: if you fail to share your link correctly.
| Reasons for Points Lost | Amount |
|---|---|
| Link shared incorrectly | -10% |
| Turned in late (per week) | -10% (up to -50%) |