Last active
October 13, 2020 21:49
-
-
Save adamoudad/233d1db8be89be5bbe1e27df32eb19c9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from tqdm import trange | |
iterations = 10 | |
with trange(iterations, unit="carrots") as pbar: | |
for i in pbar: | |
sleep(0.5) | |
if i % 2: | |
pbar.set_description(f"Testing odd number {i}") | |
else: | |
pbar.set_description(f"Testing even number {i}") | |
pbar.set_postfix(divisors=get_divisors(i)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment