Skip to content
Sign upLog in
Profile icon

mickeyM17

@mickeyM17
Repls
Community
mickeyM17
mickeyM17
published a Repl
10 days ago
0
Cursor 1
Cursor 1An extra cursor that could be handy in times!
mickeyM17
mickeyM17
published a Repl
8 months ago
0
Pascal's Triangle
Pascal's TriangleYou can access any row of Pascal's Triangle. (But the program breaks at row 57) :D
mickeyM17
mickeyM17
shared a Post
2 years ago
2
Basically, what I am saying is can I do something like this using termcolor? hi = "Hello" print(colored(hi, "World!", "red"))
Bookie0
Bookie0
Hiya! For termcolor in python, check this out and perhaps this. Basically, according to the first link: import sys from termcolor import colored, cprint text = colored('Hello, World!', 'red', attrs=['reverse', 'blink']) print(text) cprint('Hello, World!', 'green', 'on_red') printredoncyan = lambda x: cprint(x, 'red', 'oncyan') printredon_cyan('Hello, World!') printredon_cyan('Hello, Universe!') But you should use ANSI escape codes. This is how to make colors in Python. Pretty simple, jus2 years ago
stelacys
stelacys
import termcolor termcolor.cprint('Hi world!','red') Also, I don't think your hi should be outside of the string? Just a comment.2 years ago