Using VLOOKUP formula to find the total sum and using AVERAGEIF formula to find average sum

prajwalsj

New Member
Joined
Nov 22, 2022
Messages
3
Office Version
  1. 2021
Platform
  1. MacOS
Sheet 2 has information about the sales of various products for a manufacturer "XYZ" while sheet 3 has the information about the prices of these products. Using the data in Sheet 2 and Sheet 3 answer the following questions:
Q1: Using Vlookup formula, calculate the total money earned by "XYZ" during the 15 weeks for which we have the data available.
Q2: Using an averageif formula, get us the average sales volume of each product from the data.
Q3: If XYZ did a TV ad in week 4 which costed then 1.23 million Dollars, because of which they earned a total of 341 thousand Dollars, calculate the ROI(return on investment) for this ad campaign.

Interview Question.xlsx
ABC
1Product CodeWeekSales Vol
210011655
310021999
410031347
510041596
610051844
710061487
810071222
910081570
1010091849
1110101905
1210012759
1310022989
1410032719
1510042541
1610052518
1710062232
1810072613
1910082824
2010092654
2110102429
2210013995
2310023150
2410033261
2510043279
2610053187
2710063576
2810073361
2910083858
3010093258
3110103723
Sheet2


Interview Question.xlsx
CDE
1Product CodeWeekPrice
21001110
31002119
41003125
51004126
61005131
7100619
81007112
910081100
101009171
111010135
121001211
131002221
141003223
151004226
161005231
17100628
181007215
1910082106
201009270
211010234
221001310
231002321
241003325
251004325
261005330
27100639
281007314
2910083117
301009371
311010337
Sheet3
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.
This looks very much like a homework assignment. You should really be asking your course tutor for guidance, not asking us to give you the answers.

If you show us what you have tried then people will help you through any mistakes or anything that you're not quite sure about but we're not going to do your whole assignment for you.
 
Upvote 0
This looks very much like a homework assignment. You should really be asking your course tutor for guidance, not asking us to give you the answers.

If you show us what you have tried then people will help you through any mistakes or anything that you're not quite sure about but we're not going to do your whole assignment for you.
Hey Jason, I have completed the assignment with a different approach. For question 1, I have multiplied sale volume with price to get the price for each product and calculated the sum to get the total money earned by the company xyz.
For question 2, I have calculated the average sales volume per product by using pivot table.
For question 3, I have calculated the Return of investment but i was wondering if the answer is correct.
The reason for posting this thread is to get the answer for question 1 and 2 using vlookup and averageif formula respectively. I will attach the answers below for the reference.

Interview Question.xlsx
FGHI
1Total money earnedtv ad investmentreturn on investmentTotal money earned
23682866120000024828662490029.273
Sheet2
Cell Formulas
RangeFormula
F2,I2F2=SUM(E:E)
H2H2=F2-G2


Interview Question.xlsx
GH
14Row LabelsAverage of Sales Vol
151001652.8666667
161002697
171003708.0666667
181004563.6
191005588.6
201006501.0666667
211007611
221008835.5333333
231009669.2666667
241010685.0666667
25(blank)
26Grand Total651.2066667
Sheet2
 
Upvote 0
Realistically, whoever wrote the questions shouldn't be allowed to run an excel course.

For Q1. VLOOKUP is only useful for retrieving single pieces of information, a sum requires multiple pieces of information so VLOOKUP is the wrong thing to use, no competent excel user would even consider it. I might have a look at it later just for something to do but I wouldn't recommend it.

For Q2. =AVERAGEIFS(C:C,A:A,A2) would give you the average for product code 1001

For Q3. ROI is not something that I generally have to deal with, from what I can remember it is calculated as (Return - Cost)/Cost so from the example it would be (341000-1230000)/1230000 which equates to something like a 72% loss.
As I said though, not my area of expertise so that could be off the mark.
 
Upvote 0
Solution
Realistically, whoever wrote the questions shouldn't be allowed to run an excel course.

For Q1. VLOOKUP is only useful for retrieving single pieces of information, a sum requires multiple pieces of information so VLOOKUP is the wrong thing to use, no competent excel user would even consider it. I might have a look at it later just for something to do but I wouldn't recommend it.

For Q2. =AVERAGEIFS(C:C,A:A,A2) would give you the average for product code 1001

For Q3. ROI is not something that I generally have to deal with, from what I can remember it is calculated as (Return - Cost)/Cost so from the example it would be (341000-1230000)/1230000 which equates to something like a 72% loss.
As I said though, not my area of expertise so that could be off the mark.
Thanks Jason. You are absolutely correct. The questions are so confusing and lack details. I was doubting myself initially, but now I have got the clarity. These questions doesn't deserve to be posted on the platform like these. I will delete this thread soon.
 
Upvote 0

Forum statistics

Threads
1,223,888
Messages
6,175,208
Members
452,618
Latest member
Tam84

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top