def pick_gradient_value(grad_list, gradient_level):
 return grad_list[int(round(((gradient_level * (len(grad_list) - 1)) / 100)))]

def pick_gradient_value ( grad_list , gradient_level ) : return grad_list [ int ( round ( ( ( gradient_level * ( len ( grad_list ) - 1 ) ) / 100 ) ) ) ]
given a list of colors and gradient percent .