L1 Model Building Exam Activity 5 - Need Help!

I have been stuck on this problem for the past day now and have been unable to figure out where I am going wrong 😭 It says:

 

In the EMP02 Employee Expenses module, update the formulas for Bonus, Car Costs, Phone Costs, Medical costs. Update the formulas to reference the driver data in the Drivers by Role module. The employees' costs will be driven by their job role and not department.

 

This is the error message I keep getting:

 

Stuck 2.png

 

Does anyone have any advice as to what I'm doing wrong?

Tagged:

Answers

  • Hi @tspoon ,

     

    From your screenshot, it appears you're missing the line item in your 2nd LOOKUP formula. It is just saying LOOKUP:*module* rather than LOOKUP:*module*.*line item*. I imagine once you get the line item spelled out in there the formula will work just fine.

     

    Thanks,

    Timmy

  • Thanks. I tried fixing the formula to IF Employed? THEN Salary * 'EMP03 Employee Drivers by Role'.Bonus %[LOOKUP: 'EMP03 Employee Drivers by Role'.Bonus %] ELSE 0 and I am still getting an error message. I don't understand what this means at all:

     

    Stuck 3.png

     

    Here is EMP03:

     

    Stuck 4.png 

     

  • I also tried the formula:

    IF Employed? THEN 'EMP03 Employee Drivers by Role’.Bonus % [LOOKUP: 'EMP03 Employee Drivers by Role’.Department, LOOKUP: 'EMP03 Employee Drivers by Role’.Bonus %'.Role] ELSE 0

    And am also getting a message saying this is invalid
  • Hi @tspoon ,

     

    I think your 2nd formula (with lookups for Department and Role) is closer. Try replacing the Role lookup with Country instead and see if that works.

     

    Thanks,

    Timmy


  • @tspoon wrote:

    I have been stuck on this problem for the past day now and have been unable to figure out where I am going wrong 😭 It says:

     

    In the EMP02 Employee Expenses module, update the formulas for Bonus, Car Costs, Phone Costs, Medical costs. Update the formulas to reference the driver data in the Drivers by Role module. The employees' costs will be driven by their job role and not department.

     

    This is the error message I keep getting: prepaidcardstatus.com

     

    Stuck 2.png

     

    Does anyone have any advice as to what I'm doing wrong?


    4

    use filter and is instance like this

    >>> test = [1,2,3,4,5,6,"A","B"] >>> sum(filter(lambda x:isinstance(x,int),test)) 21 >>>