array rotasi kiri javascript

function rotLeft(a, d)
 {
    let rslt = a.slice(d).concat(a.slice(0,d));
    return rslt
 }
Zany Zebra