How can I print the output as
17 in 1 days
21 in 2 days
23 in 3 days
and not
17 in 0 days
21 in 1 days
23 in 2 days
const arr = [17, 21, 23];
const printForecase = function() {
for (let i = 0; i < arr.length; i++) {
console.log(`${arr[i]} in ${i} days`);
} }
printForecase();