excel problem solving situations

26
Page 1 Excel Problem Solvers – Part 1 Each of these 6 mini projects will guide you through reallife situations where Excel will help solve problems. A. Read the person’s request. Pay attention to the details. B. Create a spreadsheet using the stepbystep instructions C. Ensure that the spreadsheet fits on a single page and print.

Upload: others

Post on 12-Jun-2022

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Excel Problem Solving Situations

  Page  1  

Excel  Problem  Solvers  –  Part  1  Each  of  these  6  mini  projects  will  guide  you  through  real-­‐life  situations  where  Excel  will  help  solve  problems.    

A. Read  the  person’s  request.    Pay  attention  to  the  details.  B. Create  a  spreadsheet  using  the  step-­‐by-­‐step  instructions  C. Ensure  that  the  spreadsheet  fits  on  a  single  page  and  print.  

   

Page 2: Excel Problem Solving Situations

  Page  2  

     

1.  Basket  Ball  Team  Stats  

 …and  I  want  to  help  the  coach  calculate  some  different  stats.  I've  recorded  how  many  points  each  player  scored  during  each  game.  Could  you  help  me  figure  out  who's  scored  the  most  points  overall?"  

Our spreadsheet

Once you've downloaded our spreadsheet, open the file in Excel or another spreadsheet application. You may want to take a moment to see how the data is organized. As you can see, there is a different row for each of the players and different columns for the number of points they scored in each game.

"Hey!  There  you  are!  So,  I've  been  keeping  track  of  my  daughter's  basketball  team  with  a  spreadsheet…  

Page 3: Excel Problem Solving Situations

  Page  3  

What are we trying to figure out?

Before we write our formulas, let's think about the problem we're trying to solve. Our friend wants to find out which player scored the most points total over these five games.

Writing the formula

Now that we know what function to use, we'll start by calculating the total points scored for Tonya in row 2.

Page 4: Excel Problem Solving Situations

  Page  4  

Before we write the formula, we'll need to decide what cell range to include in the argument.

Now we're ready to write our formula. Go to the next page to see our formula in action!

Writing the formula

Now that we know what function and cell range to use, we're ready to enter our formula, =SUM(B2:F2), in cell G2:

It looks like Tonya scored 51 points total. Next, we'll drag the fill handle down to add this formula for the other players.

Page 5: Excel Problem Solving Situations

  Page  5  

There we go! It looks like Bella scored the most points overall. However, we could take it a bit further to make our data really stand out. For example, we could:

• Apply conditional formatting to highlight the highest values • Create a chart to visually compare the results • Sort the results There's really no right answer in this case—the most important thing is to make your data clear and easier to understand. In this example, it might be especially helpful to sort the data by the total points scored from highest to lowest—this will show who the top scorer is and make it easier to rank the other players on the team. Sorting works a bit differently, depending on which spreadsheet program you're using:

• For Excel 2007-2013: Select column G, then click the Descending Sort (Z-A) command on the Data tab.

• For Excel 2003 and earlier: Select column G, then click Data Sort Descending. • For Google Sheets: Select column G, then click Data Sort Sheet by column G

Descending.

Page 6: Excel Problem Solving Situations

  Page  6  

OK, now it's really easy to read our results! We can tell at a glance that Bella is the highest scorer, and we can also rank the other players.

"Wow! Thank you!

You know, I'd love to calculate some other statistics so I can tell each of the players about something they've accomplished. Could you help me figure out how many points each of the players scored in their best-scoring game?"

Highest-scoring game for each player

Now we'll need to answer this question: How many points did each of the players score in their best-scoring game?

Now that we know what function to use, we'll start by finding the highest-scoring game for Bella in row 2.

Before we write our formula, we'll need to decide what cell range to include in the argument.

Highest-scoring game

Page 7: Excel Problem Solving Situations

  Page  7  

Now that we know what function and cell range to use, we'll type our formula, =MAX(B2:F2), in cell H2 and then use the fill handle to add it to the other cells in column H.

Now we can easily see how many points each of the players scored in their highest-scoring game!

"Say, this is just great!

It's interesting to see that Hope had the highest-scoring game, even though she didn't score the most points overall. And every player scored at least 10 points in one of their games, which is something they can all be proud of! I can't wait to show this to the team. Thanks again!"    

Page 8: Excel Problem Solving Situations

  Page  8  

2.  Percent  Off  Sales    

   

"Hey, could you help me out? I want to buy some new stuff for my bike, and there's this great sale today—everything is 15% off.  Can  you  help  me  figure  out  how  much  it  will  cost  after  the  discount?  I  added  the  basic  info  to  a  spreadsheet  if  that  makes  it  any  easier."  

Our spreadsheet

Once you've downloaded our spreadsheet, open the file Excel or another spreadsheet application. Here, we have two main columns: one for the item name, and another for the item price. There's also a formula in cell B5 that calculates the original total cost of the items:=SUM(B2:B4)

What are we trying to figure out?

Let's think about the problem we're trying to solve. We want to know the total cost after the discount. A discount is a percentage of the original price. In this example, the discount is 15% of the original total.

To make this problem easier to solve with a spreadsheet, we'll break it down into two steps:

1. Find the discount, which is 15% of $78.77. 2. Subtract that value from the original total to find the final cost.

Page 9: Excel Problem Solving Situations

  Page  9  

Step 1: Find the discount

We know that we need a formula that will calculate 15% of $78.77. Whenever you see the phrase "of something" in a percentage problem, it's a hint that you need to multiply. So we'll need to multiply $78.77 by 15% to find the discount. When you're using percentages within formulas, you'll want to write them as decimals.

Excellent! Now that we know how to write 15% as a decimal, we're ready to write our formula:

=B5*0.15

We'll type this formula in cell B6 and then press Enter:

And here's our answer: The discount is $11.82.

Step 2: Subtract the discount from the original total

Now that we've calculated our discount, we'll subtract that value from the original total. Here's our formula:

=B5-B6

We'll type this formula in cell B7 and press Enter:

Page 10: Excel Problem Solving Situations

  Page  10  

The final price after the discount will be $66.95.

"So, I'll save about $12?

Nice! I figured it'd be around that much, but I always like to know exactly how much I'm spending! Thanks so much—and let me know if you want to hit the bike trail soon!"

Bonus section: Alternate solution

In the example above, we found the discount and then subtracted that from the original total. To make this simpler, we broke the problem down into two smaller steps. However, if you're comfortable working with percentage problems, we could have found the same answer with only one formula.

Because we know we'll get 15% off, you could also say the final cost would be 85% of original total. Just like before, we can find a percentage of something by multiplying. So we'll multiply the original price by 0.85. Here's our formula:

=B5*0.85

Page 11: Excel Problem Solving Situations

  Page  11  

As you can see, this formula gives us the same result as the example above: $66.95.

     

Page 12: Excel Problem Solving Situations

  Page  12  

3.  Free  Shipping  

"Howdy! I heard that you're good with spreadsheets, so I thought I'd ask for a favor.

You probably know that we currently charge $5.99 for shipping on all of our orders. Well, we're going to start offering free shipping if the subtotal of an order is at least $100. Do you think you could update our invoice to calculate this automatically?"

Our spreadsheet

Once you've downloaded our spreadsheet, open the file in Excel or another spreadsheet application. It looks like we have an order invoice. There's information about the order, along with some formulas to calculate the tax, order subtotal, and total order cost.

How can we solve this problem?

If the subtotal for an order is at least $100, the shipping should be free. If not, it should cost $5.99. We could use theIF function to solve this problem. As you may remember from our lesson on Using the IF Function, we can use it to test a condition and then write something in a cell depending on the result. In this example, the IF function can tell us whether the subtotal is at least $100 and then set the shipping cost depending on the result.

Page 13: Excel Problem Solving Situations

  Page  13  

Writing the function

• The first argument sets up the condition the IF function will test: In this example, if the value in cell D6 is greater than or equal to 100. So our first argument will be D6>=100.

• The second argument tells the function what to write if the condition is true. In this example, if the value is greater than or equal to 100, we want it to write "0" in the cell. So our second argument will be 0.

• The third argument tells the function what to write if the condition is false: In this example, if the value is less than 100, we want it to use the value from cell G3 (5.99). So our third argument will be $G$3 (we'll use an absolute reference here just in case we move this formula in the future).

Here's our function: =IF(D6>=100,0,$G$3). We'll enter this function into cell D7.

If you entered the function correctly, the shipping cost should change from $5.99 to $0.00. That's because the OrderSubtotal is more than $100.

If you want to test the function, change the value in cell C2 from 2 to 1. Because the Order Subtotal is now less than $100, the Shipping cost should change from $0.00 to $5.99.

Page 14: Excel Problem Solving Situations

  Page  14  

OK—our function is working really well! We're ready to send this back!

"Perfect-o! Thanks for doing this!

This kind of automation is going to make everything a lot simpler. I'll be sure to send all of my complicated spreadsheet problems your way from now on."      

Page 15: Excel Problem Solving Situations

  Page  15  

04  Movie  Tickets  and  Popcorn      

"Hey, could you help me out here? I'd like to take three of my friends to see a movie—that includes you, of course! I  also  don't  want  to  spend  more  than  $50.00.  The  tickets  cost  $11.75,  so  I  want  to  know  how  much  money  I'll  have  left  over  for  drinks  and  popcorn  after  buying  the  tickets.    I'll  bet  you  could  use  a  spreadsheet  to  crunch  the  numbers."  

Our spreadsheet

Once you've downloaded our spreadsheet, open the file in Excel or another spreadsheet application. We'll just need to enter a few different values to get started. Our friend Darien told us that a ticket costs $11.75, so we'll enter that in cell B1. He'll need 4 tickets (one for himself and three for his friends), so we'll enter 4 into cell B2. Finally, Darien said he didn't want to spend more than $50.00, so we'll enter that in cell B3.

How can we solve this problem?

Darien wants to know how much money he'll have after buying the tickets. To simplify the problem, we're going to break it down into two steps:

1. Figure out how much the tickets will cost. 2. Subtract that amount from the total budget to find our answer.

Page 16: Excel Problem Solving Situations

  Page  16  

Writing the formulas

Let's start by calculating the cost of the tickets. To find the answer, we'll multiply the cost of the tickets by the number of tickets needed. Those values are stored in cells B1 and B2. So here's our formula:

=B1*B2

We'll type this formula into cell B4:

OK, the tickets will cost $47.00. Now, we'll subtract that value from the total budget in cell B3. Here's our formula:

=B3-B4

We'll type this formula into cell B5:

So if Darien buys 4 regularly priced tickets, he'll have $3.00 left over for popcorn and drinks.

"Whoa—only $3.00!? I won't be able to buy any extra snacks with that!!

Page 17: Excel Problem Solving Situations

  Page  17  

You know, there's also a matinee show for this movie, and the tickets only cost $7.25. How much would I have left over if we went to the matinee instead of the evening show?" Since we used cell references to write our formulas, we can simply change the ticket cost in cell B1 from $11.75 to $7.25—our formulas will then recalculate automatically.

OK, Darien will have $21.00 left over if he chooses to go to the matinee showing of the movie! Let's send this back to him.

"Cool—thanks for doing this!

I was thinking the matinee would be less expensive, but I didn't realize just how much I'd save overall! I hope you like action movies because one of these tickets has your name on it!"

Bonus section: Alternate solution

In the example above, we used two different formulas to make the problem easier to solve. But if you're already familiar with the order of operations, you might have realized that we could have written it as one formula:

=B3-B1*B2

Page 18: Excel Problem Solving Situations

  Page  18  

This formula gives us the same answer as the example above: $21.00. As you may remember from the lesson onComplex Formulas, spreadsheets use the order of operations to determine which operations to perform first in a formula. Because multiplication comes before subtraction, this formula will first multiply the values in cells B1 and B2 and then subtract that value from the budget total in cell B3. Of course, it's up to you to determine how you want to solve problems in a spreadsheet. However, as you become more confident with using the order of operations, you may find it easier to write only one formula to solve complex problems, as in the example above.

     

Page 19: Excel Problem Solving Situations

  Page  19  

05  Free  Gifts  for  Big  Donors  

"Hey! So as you know, we recently completed our semi-annual fundraiser.

If anyone gave at least $50, they'll receive a free tote bag. I was going to type Free Gift for each person who donated at least $50, but I'm really busy today. Do you think you could handle this for me?"

Our spreadsheet

Once you've downloaded our spreadsheet, open the file in Excel or another spreadsheet application. As you can see, our coworker Jordan has already added a ton of information—there are several different columns, and each row contains the contact information for one person, along with the amount of money that person donated.

How can we solve this problem quickly?

So if a person donated at least $50, we need to write the words Free Gift in that donor's row. We could go through each row, look at the value, and then write Free Gift if the value is at least $50. But there are a lot of people on the spreadsheet, so it could be really time consuming to do this manually. What we really need is way to make our spreadsheet do this automatically.

Page 20: Excel Problem Solving Situations

  Page  20  

While you might never have used it before, the IF function can simplify these kinds of problems. The IF function can look at a value in a cell to see if it meets a basic condition (in our example, if the value is greater than or equal to 50). Then it can then add text to an empty cell. Here, we can use the IF function to look at each person's donation, then add the words Free Gift if they donated at least $50. Basically, the IF function can do the same thing we were planning to do, only it can do it much faster.

Prepare the spreadsheet

If you've never used the IF function before, don't worry—it's not complicated, although the syntax is a bit different from other formulas you may have used. Before you get started, it's best to decide where the results from the function will go. In our case, we'll go ahead and insert a new column to the right of column G.

Writing the function

Now that we have our new column, we'll start building our formula. We'll need to have a formula on each row, so we'll start by typing the formula in cell H2. As with any formula, you'll start with an equals sign (=). Then type the function name, followed by an open parenthesis. So far, it should look like this:

=IF(

Now, we'll add our arguments. The arguments will tell the IF function what to look for and what to write in the cell depending on the outcome.

The first argument sets up the condition we want to test. For this formula, we want to know if the value in cell G2 is greater than or equal to 50. We'll use some mathematical operators ( > for greater than and = for equals ) to write the condition:

=IF(G2>=50

Page 21: Excel Problem Solving Situations

  Page  21  

The next argument will tell the function what to write if the condition is true (that is, if the value is greater than or equal to 50). This means the person will be getting a free gift, so we'll have it write Free Gift. Because this argument is text, we'll need to put it in double quotes (" "). And, as with any function, we'll need to use a comma to separate each argument:

=IF(G2>=50, "Free Gift"

The final argument will tell the function what to write if the condition is false. This means the person won't get a free gift. We could make the function write something like None or No, but in this case we actually just want the cell to remain blank. To do this, we'll just type double quotes ("") with no text inside. This is also our last argument, so go ahead and close the parentheses:

=IF(G2>=50, "Free Gift", "")

OK, you're done! When you press Enter, the words Free Gift should appear in the cell.

Now we can just drag the fill handle down to add the formula to the other cells in column H:

Page 22: Excel Problem Solving Situations

  Page  22  

Excellent—our function is working perfectly! If we wanted to go a step further, we might sort or filter the results to show only those donors who earned the free gift. For now, it

looks like we're ready to send this back.

"Perfect! This is exactly what I wanted!

I don't know how you did it so fast, but it really saves me a lot of trouble. You know, I think we probably have a spare tote bag if you want one for yourself!"

     

Page 23: Excel Problem Solving Situations

  Page  23  

06  Choose  a  Printer    

 "Hey  hey!  So,  we're  buying  a  new  printer  for  the  office,  and  we're  trying  to  decide  between  these  two:  the  Nidi  2600  and  the  Ace  X1.  Can you help us figure out which one would be cheaper in the long run? Keep in mind that we probably won't buy another printer for at least three years. Also, we're printing an average of about 12,000 sheets per year."

Building the spreadsheet

It looks like our coworker Carter has already done some research and collected information about each of these printers:

This is all useful information, but it's not very consistent or well organized. In order to compare these two printers, we'll need to make sure our spreadsheet organizes the data consistently, which means we'll need to move some things around.

If you look at the following spreadsheet, you'll see that we've rearranged the printer cost, cartridge cost, and number of sheets per cartridge so we have a clear, side-by-side comparison of the two printers. We've also added the total number of sheets printed per year, since we'll need to use that value in our formulas.

See how this format makes it easy to compare the different information for each printer? Now that we have our spreadsheet organized, we're ready to start solving this problem.

Page 24: Excel Problem Solving Situations

  Page  24  

How can we answer this question?

We'll use the spreadsheet to answer this question: Which printer will be less expensive over the course of three years? The cost of each printer will be determined by two things:

• The original cost of the printer • The cost of toner cartridges needed over a three-year period

Writing the formulas

We already know the original costs of the printers—those values are stored in cells B2 and C2. This means we'll just need to figure out the total cost of the cartridges over three years. There are many different ways to go about this, but to make it simpler we'll break it down into multiple steps.

First, we'll calculate how many toner cartridges we'd need to purchase each year for each printer. We know the office prints about 12,000 sheets of paper per year (that value is stored in cell F2). If we divide that by the number of sheets per cartridge, we can determine how many cartridges we'll need over one year. Here are our formulas:

• In cell B5, type =$F$2/B4 • In cell C5, type =$F$2/C4 (Note: You can also just copy and paste the formula from cell

B5.)

OK, it looks like we'd need to purchase 24 cartridges over one year for the Nidi and only 12 for the Ace.

Next, we'll calculate how much money we'll spend each year on cartridges. Because we just calculated the number of cartridges, we just need to multiply that value by the cartridge price:

• In cell B6, type =B5*B3 • In cell C6, type =C5*C3 (or copy the formula from cell B6)

Page 25: Excel Problem Solving Situations

  Page  25  

It looks like cartridges would cost $420 each year for the Ace and $600 each year for the Nidi. Next, we'll multiplythose values by 3 to determine the cost for three years. Here are our formulas:

• In cell B7, type =B6*3 • In cell C7, type =C6*3

Finally, we'll add the printer cost and the cartridge cost over three years to determine the total cost over three years for each printer. Here are our formulas:

• In cell B8, type =B7+B2 • In cell C8, type =C7+C2

Page 26: Excel Problem Solving Situations

  Page  26  

And there's our answer! As you can see, the Ace X1 is cheaper than the Nidi 2600 in the long term, even though the upfront costs for the Nidi are much lower. And because the yearly cartridge cost for the Ace X1 is much lower, we'll continue to save money the longer we keep this printer.

"Excellent work here! I didn't expect the Ace to be such a good deal…

…but I guess the savings from those bigger toner cartridges really add up over time! Maybe we can have a pizza party with the extra money we'll save!"