const num = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
function mostrarDetalhesArray(array){
for(let i = 0; i < array.length; i++){
const position = array.indexOf(array[i]);
const value = array[i];
console.log(`${position} - ${value}`);
}
}
mostrarDetalhesArray(num);