var items = ['f','d','e','s','g','j','k','l','w'];
function getRandomElements(arr, count) {
var shuffled = arr.slice(0), i = arr.length, min = i - count, temp, index;
while (i-- > min) {
index = Math.floor((i + 1) * Math.random());
temp = shuffled[index];
shuffled[index] = shuffled[i];
shuffled[i] = temp;
console.log(shuffled[i])
}
return shuffled.slice(min);
}
// console.log( getRandomElements(items, 4) );
getRandomElements(items, 4)