from typing import List


def accuracy(results: List[bool], expected: List[bool]) -> float:
    """
    Calculates the accuracy of a set of data
    :param results: Target results data
    :param expected: Output results data
    :return: The accuracy of the results
    """

    n: int = len(results)
    return sum(1 for i in range(n) if results[i] == expected[i]) / n