diff options
| author | 2023-11-19 16:55:03 +0100 | |
|---|---|---|
| committer | 2025-12-01 09:53:01 +0100 | |
| commit | d7e30321ae6ae4c82a8ab7455f6ce33afd719c67 (patch) | |
| tree | e873d640f909ae3e247adc7661b7d954c8af3a26 /aoc/utils.py | |
| download | 2025-d7e30321ae6ae4c82a8ab7455f6ce33afd719c67.tar.gz 2025-d7e30321ae6ae4c82a8ab7455f6ce33afd719c67.tar.bz2 2025-d7e30321ae6ae4c82a8ab7455f6ce33afd719c67.zip | |
Initial commit
Diffstat (limited to 'aoc/utils.py')
| -rw-r--r-- | aoc/utils.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/aoc/utils.py b/aoc/utils.py new file mode 100644 index 0000000..a5de050 --- /dev/null +++ b/aoc/utils.py | |||
| @@ -0,0 +1,6 @@ | |||
| 1 | # -*- coding: utf-8 -*- | ||
| 2 | from typing import Callable | ||
| 3 | |||
| 4 | |||
| 5 | def bold(item: str, condition: Callable[[], bool]): | ||
| 6 | return f"\033[36m{item}\033[0m" if condition() else item | ||
