(number, region_code="1")
return number
Add country code to North American Numbering Plan phone number

    https://en.wikipedia.org/wiki/National_conventions_for_writing_telephone_numbers
    #United_States,_Canada,_and_other_NANP_countries
Add country code to North American Numbering Plan phone number
Add country code to North American Numbering Plan phone number
def add_nanp_prefix(number, region_code="1"):
    """Add country code to North American Numbering Plan phone number

    https://en.wikipedia.org/wiki/National_conventions_for_writing_telephone_numbers
    #United_States,_Canada,_and_other_NANP_countries
    """
    if len(number) == 10 and number[0] not in "01":
        number = region_code + number
    return number
def add_nanp_prefix ( number , region_code = "1" ) : if len ( number ) == 10 and number [ 0 ] not in "01" : number = region_code + number return number