Can't pass " Use Destructuring Assignment to Assign Variables from Objects "

Can't pass " Use Destructuring Assignment to Assign Variables from Objects "
0

#21

Did come off a little jerky but not much. Doesnt matter though because your guidance helped me pass the challange as well. Thanks snowmonkey.


#22

Thanks for the good comments on the suggestions. We have a lot more knowledge is good.:ta สมัคร UFABET
สมัครเอเย่นต์
แทงบอลออนไลน์


#23

had the same problem, thank you snowmonkey for clearing things up!


#24

Thanks for the good comments on the suggestions. We have a lot more knowledge.:ta สมัคร UFABET
สมัครเอเย่นต์
แทงบอลออนไลน์


#25

Im also get problem with this challenge,

Summary
const AVG_TEMPERATURES = {
 today: 77.5,
 tomorrow: 79
};

function getTempOfTmrw(avg) {
 "use strict";
 // change code below this line
const { tomorrow: tempOfTomorrow } = avg; 
 // change code above this line
 return tempOfTomorrow;
}

console.log(getTempOfTmrw(AVG_TEMPERATURES)); // should be 79

In console i see

Summary

// running tests
destructuring with reassignment was used
// tests completed


#26

Have you changed variables or function names? If you see a “don’t change code below/above this line” you have to respect that to pass the challenge


#27

Always glad to help. Best of luck, and you have no idea how happy I am to see so many folks searching the forum rather than simply asking the same question over again.

:smiley:


#28

Okay, so you changed the parameter name from avgTemperatures to avg. Yes? Don’t.

The code you’re given contains two lines:

...
 // change code below this line
...
 // change code above this line
...

In changing that variable name, you went outside the lines you were expressly told to edit. There is a test hook that is looking for avgTemperatures, and you’ve broken it.


#29

jes. im so stupid xD first time i used
const { tomorrow: tempOfTomorrow } = AVG_TEMPERATURES;
Next time code from my prev msg. and now i see what’s i did wrong. ty snowmonkey