Python script that outputs rainbow BBCode