JSFiddle - React, Tailwind, and code Playground

by Jessie Lau

JavaScript

var passengers = [ ["Thomas", "Meeks"],
                   ["Gregg", "Pollack"],
                   ["Christine", "Wong"],
                   ["Dan", "McGaw"] ];
var modifiedNames = passengers.map(function (firstAndLast) {
  return firstAndLast[0] + " " + firstAndLast[1];
});