function solution(lottos, win_nums) {
// 당첨 번호와 로또 번호 중 일치하는 숫자의 개수를 세어서 저장
const correct = lottos.filter(lotto => win_nums.includes(lotto)).length;
// 로또 번호 중에서 0의 개수를 세어서 저장
const zeros = lottos.filter(lotto => lotto === 0).length;
// 최소 등수를 구함
let min = 7 - correct >= 6 ? 6 : 7 - correct;
// 최대 등수를 구함
let max = min - zeros < 1 ? 1 : min - zeros;
// 최소 등수와 최대 등수를 배열에 담아서 반환
return [max, min];
}