forked from ndleah/python-mini-project
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
31 lines (26 loc) · 674 Bytes
/
main.py
File metadata and controls
31 lines (26 loc) · 674 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import sys
import pyfiglet
# Banner maker
def ascii_maker():
print('-' * 70)
ascii_banner = pyfiglet.figlet_format("A C I I banner").upper()
print(ascii_banner)
print('-' * 70)
text = input("\nEnter Your Text: ")
banner = pyfiglet.figlet_format(f"{text}").upper()
print(banner)
# Ending message
def ending():
print("\n\nThanks for using the code :)\n")
a = input("Do you want to run the program again? (y for yes) (any key for no): ")
if a.lower() == 'y':
return True
else:
sys.exit()
# Main loop
def run_loop():
while True:
ascii_maker()
if not ending():
break
run_loop()