Hello every one
Can not pass quiz …
link to quiz https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/es6/use-destructuring-assignment-to-assign-variables-from-objects/
in console print error : destructuring with reassignment was used
what is wrong with code ?
const AVG_TEMPERATURES = {
today: 77.5,
tomorrow: 79
};
function getTempOfTmrw(avgTemperatures) {
"use strict";
// change code below this line
const {today: a ,tomorrow: b } = AVG_TEMPERATURES;
const tempOfTomorrow = b; // change this line
// change code above this line
return tempOfTomorrow;
}
console.log(getTempOfTmrw(AVG_TEMPERATURES)); // should be 79