Wrote function to return color value