New-Member-13 The Christmas List
Closed this issue · 0 comments
theonlyexception commented
New-Member-13-The Christmas List
Santa has just finished the Christmas delivery but it's the time he dreads, when he starts getting letters from upset children stating they have been given the wrong presents.
We all know Santa checks his list twice but he also checks a third time after delivery
Help Santa to make sure that all the presents were delivered correctly by writing a function that takes two objects and compares whether they are the same
christmasMasterList2015 = {
Johnny: "coal",
Petey: "Monster Truck",
Tommy: "Iphone 6 plus with unlimited 4g contract"
}
presentsDelivered2015 = {
Johnny: "coal",
Petey: "Monster Truck",
Tommy: "Iphone 6 plus with unlimited 4g contract"
}
presentsDelivered2014 = {
Johnny: "coal",
Petey: "Tricycle",
Tommy: "Marvel Unlimited Subscription"
}
Example
allPresentsDelvieredCorrectly(christmasMasterList2015, presentsDelivered2015)
//returns true
allPresentsDelvieredCorrectly(christmasMasterList2015, presentsDelivered2014)
//returns false