Potentially useful extensions to Swift arrays. Inspired by underscore.js