Answers for "what does from colorama import Fore"

2

how to use colorama

# Colorama is a module to color the python outputs
# 1. You have to install python with pip
# 2. go to your commandline and type:
#	linux: sudo pip install colorama
#	windows + mac: pip install colorama
# 3. wait for the download and then create a new python file
# 4. use the module colorama
import colorama
from colorama import Fore, Back, Style
# 5. the best way is to use colorama with f-strings
colorama.init(autoreset=True)#auto resets your settings after every output

print(f"{Fore.GREEN}green is one of the colors, there are many other colors!")
Posted by: Guest on December-25-2020
0

how to install colorama

Installing with pip is almost always the way to go. 
It will handle downloading the package for you, as well as any dependencies. 
If you do not have pip, 
see http://www.pip-installer.org/en/latest/installing.html.

Then

pip install colorama
or
sudo pip install colorama

Ba-boom! Done.

Source
https://stackoverflow.com/questions/9846683/how-to-install-colorama-python
Posted by: Guest on November-08-2020

Python Answers by Framework

Browse Popular Code Answers by Language