Answer:
def get_area_code(phone_number):
return phone_number[1:4]
# Testing function
print(get_area_code('(555)867-5309'))
print(get_area_code('(254)867-5309'))
print(get_area_code('(181)867-5309'))
9.4m questions
12.2m answers