There are console.log statements in the javascript loop, but there is no loop printing

When the

function is running, press the keyboard "z" or "x", and the middle 0 will move left and right instead of printing in a loop all the time. Why?
I would like to ask you why when this function runs, press the keyboard "z" or "x", the middle 0 will move left and right, instead of printing
[picture]
clipboard.png

all the time.
Mar.22,2021

I found this
Node.js console.log on the Internet. Can I update a row instead of creating a new one?


The

output uses a special control transfer sequence \ x1B [1A to move the cursor up one line, and \ x1B [K means to erase the contents of the current cursor to the end of the line, which is equivalent to clearing the contents of the previous line. So you only see a line from beginning to end |-- 0murf-| output.

you can remove \ x1B [1A\ x1B [K ] to check the output and you can see the loop output you expect.

Menu