["1.cad", "2.bat", "1.aa.doc", "1.aa.aa", ".aa", "1.aa"]
['.aa', '1.aa', '1.aa.aa', '1.aa.doc', '1.cad', '2.bat']
btn.addEventListener('click', (event) => {
if (block.classList.contains('active')) {
hide()
} else {
show();
}
});
btn.addEventListener('click', (event) => {
block.classList.contains('active') ? hide() : show();
});
Вывожу в консоли
console.log(`arr[${i}][${j}] * ${max}`)
Получаю