Issue
How can I implement a progress bar like apt, so that it won't interfere with other output?
Any language would be fine.
Solution
You can try to use tqdm
library.
Example from their github page:
from tqdm import tqdm
for i in tqdm(range(100)):
print(i)
You can look at their source code and see how it's implemented. I think they use the best practices in this subject: tqdm on github
Note that there also exists other libraries in python and other languages so you can check them out as well.
Answered By - Nurjan Answer Checked By - Willingham (WPSolving Volunteer)