Phone number with regex | SoloLearn: Learn to code for FREE!

0

Phone number with regex

I solved this problem but i need to make the phone number length 8 numbers and its not working with me

10/25/2020 10:25:29 AM

Mariam Mohamed

4 Answers

New Answer

+1

CarrieForle question isn't about getting length of phone number !

0

len(phone_number)

0

{} indicates how many times the previous values should repeat. For example: r'^[a-z]{8}$' will match only words that contain alphabetical values of length 8.

0

Here live code for phone numbers with regular expressions: https://code.sololearn.com/cx1tfbykB3pp/?ref=app