Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Python by (16.4k points)

For python, I've downloaded colorama, Then I also imported the module:

import colorama

from colorama import init

init()

from colorama import Fore, Back, Style

print Fore.RED + "My Text is Red"

Then, it returns:

esc[31mMy Text is Red

I don't know where I went wrong.

1 Answer

0 votes
by (26.4k points)

Try the following code:

from colorama import init, Fore, Back, Style

init(convert=True)

print(Fore.RED + 'some red text')

Join the python training course to learn python in detail.

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Browse Categories

...