Implemented alternative colouring function