def dedent(text: str) -> str:
    """Remove indentation from a multiline string."""
    text = text.strip("\n")
    indent = text.split("\n")[0].count("    ")
    return text.replace("    " * indent, "")