def anonymize_ip(real_ip: str) -> str:
    """
    Sets the last byte of the IP address `real_ip`.

    .. note::
        It is a good step but it may be possible to find out the physical address
        with some efforts.

    Example:
        If the input is "595.42.122.983", the output is "595.42.122.0".

    Raises:
        ValueError: ``real_ip`` must have 4 blocks separated with a dot.

    Args:
        real_ip (str): Full IPv4 address.

    Returns:
        str: ``real_ip`` with the last `byte` zeroed.
    """
    anonymized_ip = real_ip.split(".")
    if len(anonymized_ip) != 4:
        raise ValueError("Bad format of the IP address '" + real_ip + "'")
    anonymized_ip[3] = "0"
    return ".".join(anonymized_ip)