Might be worth noting that you can 'skip' indexes in array destructing by doing:
const [,,biology] = scores;
Although I admit I think when you use array destructuring like this it looks awful. So it's probably only useful if you need to skip one or two items and pull out a bunch. (Rather than using it for a single index as I did above)
Might be worth noting that you can 'skip' indexes in array destructing by doing:
Although I admit I think when you use array destructuring like this it looks awful. So it's probably only useful if you need to skip one or two items and pull out a bunch. (Rather than using it for a single index as I did above)
But great post!
Thank you for the tip. 😊