def _calculate_control_doi(doi: str) -> str:
        """
        Calculate the letter that corresponds to the end of a DOI
        :param doi: calculated value so far needing a control character
        :return: DOI control character
        """

        lookup = "TRWAGMYFPDXBNJZSQVHLCKE"
        return lookup[int(doi) % 23]

        Calculate the letter that corresponds to the end of a DOI
        :param doi: calculated value so far needing a control character
        :return: DOI control character
        
faker/providers/ssn/es_ES/__init__.py