Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- =====================
- name 'coloring' is not defined
- # import colorama
- # colorama.init()
- def coloring(string, color):
- '''Мой мини-модуль для раскрашивания текста'''
- if color == "red":
- string = "\x1b[31m" + string + "\x1b[0m"
- elif color == "green":
- string = "\x1b[32m" + string + "\x1b[0m"
- elif color == "yellow":
- string = "\x1b[33m" + string + "\x1b[0m"
- elif color == "blue":
- string = "\x1b[34m" + string + "\x1b[0m"
- else:
- pass
- return string
- if __name__ == '__main__':
- pass
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement