def has_few_assignments(example, minimum=4):
    """Check if file uses symbol '=' less than `minimum` times."""
    lines = example["content"].splitlines()
    counter = 0
    for line in lines:
        counter += line.lower().count("=")
        if counter > minimum:
            return {"has_few_assignments": False}
    return {"has_few_assignments": True}
Check if file uses symbol '=' less than `minimum` times.
dpkd/transformers/examples/research_projects/codeparrot/scripts/preprocessing.py