lots of cleanup

This commit is contained in:
Ruediger Ludwig 2022-12-10 19:30:10 +01:00
parent 7d0d3e504e
commit 0385cbd62e
26 changed files with 337 additions and 417 deletions

View file

@ -53,7 +53,7 @@ def draw(lines: Iterator[str], width: int, height: int) -> list[str]:
picture = ""
for cycle, sprite in enumerate(cycles(lines)):
crt_pos = cycle % width
if sprite - 1 <= crt_pos and crt_pos <= sprite + 1:
if sprite - 1 <= crt_pos <= sprite + 1:
picture += '#'
else:
picture += ' '