checkRange=(a,x,y)=>a.map(b=>n+=b<x==b>y,n=0)|n
checkRange=(a,x,y,c=0)=>a.map(v=>c+=v<x==v>y)|c
function checkRange(array, x, y, counter = 0) {
return array.map(item => counter += ((item < x) == (item > y))) | counter
}
checkRange([2, 5, 6, 7, 1, 3, 4, 11, 56, 49],1,7)
return [1, 2, 3, 4, 5, 6, 7, 7, 7, 7] | 7 // возращает 7
const allImages = [{img: 'userImage.jpg', filter: 'фото салона'}, и т.д.]