/**
 * Shuffle an array.
 * @function lib.array.shuffled
 * @param {array} array - Array to shuffle.
 * @returns {array} - Shuffled array.
 * @author Taka Okunishi
 */
module.exports = function (array) {
    return [].concat(array).sort(function () {
        return Math.random() - Math.random();
    });
};