Both objects and arrays support destructuring, meaning that you can extract values from them and assign them to named variables:A Functional Programmer’s Introduction to JavaScript (Composing Software)6.8K54Eric ElliottRandy MacDonaldFollowFeb 25, 2017 · 1 min readKnowing Prolog’s unification concept makes the following ideas quite natural.