Cleaned up Rainbow Code