02-24-2010, 12:52 PM
Well in python there is a module called termcolor That allows you to do this. It is has a very simple function that takes two arguments, the string and the desired colour. Besides it's other functions, it lets you print in grey, red, green, yellow, blue, magenta, cyan, white.
Here is my script.
Of course this varies for different operating systems, to know if yours will print coloured text click the link above.
Here is my script.
Code:
from termcolor import *
print colored('Hello World\n', 'green')
print colored('Hello World\n', 'red')
print colored('Hello World\n', 'cyan')
print colored('Hello World\n', 'magenta')