from typing import Callable
from typing import Sized


def minimum_length(length: int) -> Callable:
    """Generate a function that checks for a minimum string length."""
    def _min_len(value: Sized) -> float:
        if length > len(value) > 0:
            return 0.
        return 1.
    return _min_len