const maxKey = arr.reduce((a,c,v)=>(v=Object.values(c)[0],v<a.v?a:{k:Object.keys(c)[0],v:v}),{k:0,v:-Infinity}).k;
const maxElem = arr.reduce((a,c,v)=>(v=Object.values(c),v<a.v?a:{k:c,v:v}),{k:0,v:0}).k;
if(res.includes(array[i]) ) return res.push(array[i])
const arr = [1,2,3,4,5,6]
let num = 10
let index = 3
while ( num > 0 ) {
if ( !arr[index] ) {
index = 0
}
arr[index] += 1
index++
num--
}
console.log( arr )
clip-path: polygon(0% 0%, 100% calc(0% + 60px), 100% calc(100% - 60px), 0% 100%);
/* calc(100% - 60px) -- вот тут задал четкую ширину скоса */