delete previous line node

JavaScript
for (let i = 0; i < 100; i++) {
  process.stdout.write(`\rProgress: ${i + 1}/100`);
}

console.log(); // final new line
Source

Also in JavaScript: