Slightly challenging one. Find the potential bug.
const arr = [1, 2, 3, 4, 5]
for (let i = arr.length - 1; 0 < i; i--) {
const j = Math.floor(Math.random() * (i + 1))
[arr[i], arr[j]] = [arr[j], arr[i]]
}