Created
March 4, 2018 02:05
-
-
Save dance2die/ba57bf94913338798cc4769647efc021 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function concatDemo(orders) { | |
const firstOrder = [orders[0]]; | |
const lastOrder = [[...orders].pop()]; | |
const firstAndLastOrders = firstOrder.concat(lastOrder); | |
printOrders(firstAndLastOrders); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment