def computeHSL(hexValue):
    """
    Given a six-digit hex code (no #), compute the hue, saturation, and
    luminosity. Returns a list consisting of the hue, saturation, and
    luminosity values. Hue is a (float?) between 0 and 360, luminosity and
    saturation floats between 0 and 1
    """

    red = int('0x' + hexValue[0:2], 16)
    green = int('0x' + hexValue[2:4], 16)
    blue = int('0x' + hexValue[4:6], 16)

    redF = float(red) / 255
    greenF = float(green) / 255
    blueF = float(blue) / 255

    colorList = [redF, greenF, blueF]
    maxColor = max(colorList)
    minColor = min(colorList)

    L = maxColor + minColor / 2

    if maxColor == minColor:
        S = 0
        H = 0
    else:
        if L < .5:
            S = (maxColor - minColor) / (maxColor + minColor)
        else:
            S = (maxColor - minColor) / (2 - maxColor - minColor)
        if redF == maxColor:
            H = (greenF - blueF) / (maxColor - minColor)
        elif green == maxColor:
            H = 2 + (blueF - redF) / (maxColor - minColor)
        else:
            H = 4 + (redF - greenF) / (maxColor - minColor)

        H = (H / 6) * 360

    return [H, S, L]