You can copy and paste the code from python terminal colors · GitHub (I recommend bookmarking it)
Here’s how you can use them:
BLACK = '\033[30m'
RED = '\033[31m'
GREEN = '\033[32m'
YELLOW = '\033[33m'
BLUE = '\033[34m'
MAGENTA = '\033[35m'
CYAN = '\033[36m'
WHITE = '\033[37m'
RESET = '\033[39m'
print(f'Hello {BLUE}world!{RESET}')
thank you this is the most helpfull responce on this post
No problem. Welcome to the community BTW =D
did you just say you’re gonna cheat?
lol best answer is no answer I guess @FenixPenning , but seriously, could you please not cheat/elaborate?
no O_O u heard nothing o_o
Ok but can you elaborate?
yea sure
im typing this to remove the minimum carictars
Ok um that’s not an… explanation
it was a joke ok im just trying to have a little fun because im exited my code worked rn
The last time I saw somebody say this was for help for school they got in trouble with the mods because it people use Replit to cheat, it gets banned in schools. So be careful what you say.
ooohhh, lol sorry about bothering you
@bigminiboss’s is very good, but you can also do
import colorama
and then you can do things like:
print(f"{colorama.Fore.BLUE}This text is blue!")
This will output the text in blue. There are also many other Fore colors, the colorama documentation has them all: Documentation
I wouldn’t use colorama since it has some disadvantages I can’t remember off the top of my head but yes that works