<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def max_validator(max_value):
 """Return validator function that ensures upper bound of a number. Result validation function will validate the internal value of resource instance field with the ``value >= min_value`` check. Args: max_value: maximum value for new validator """

    def validator(value):
        if value > max_value:
            raise ValidationError("{} is not <= {}".format(value, max_value))

    return validator