From 5f1678cb6d32a038bcbe8ca44d22be58c2347779 Mon Sep 17 00:00:00 2001 From: manetta Date: Tue, 1 Dec 2020 15:00:44 +0100 Subject: [PATCH] adding ascii art --- ascii-art/blobs.py | 50 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 ascii-art/blobs.py diff --git a/ascii-art/blobs.py b/ascii-art/blobs.py new file mode 100644 index 0000000..dc3b492 --- /dev/null +++ b/ascii-art/blobs.py @@ -0,0 +1,50 @@ +import random + +width = 61 +lines = 8 + +char = 'o' +space = ' ' + +ascii = '' + +for line in range(lines): + for x in range(width): + if line == 0: + ascii += char + if line == 1: + if x % 2 == 0: + ascii += char + else: + ascii += space + if line == 2: + if x % 3 == 0: + ascii += char + else: + ascii += space + if line == 3: + if x % 4 == 0: + ascii += char + else: + ascii += space + if line == 4: + ascii += space + if line == 5: + if x % 2 == 0: + ascii += char + else: + ascii += space + if line == 6: + if x % 4 == 0: + ascii += char + else: + ascii += space + if line == 7: + if x % 5 == 0: + ascii += char + else: + ascii += space + + ascii += '\n' + +print(ascii) \ No newline at end of file