Skip to content

davidKolesar/ValidatePhoneNumber

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

ValidatePhoneNumber

Method that accepts a string, and returns true if it is in the form of a phone number.

Assume that any integer from 0-9 in any of the spots will produce a valid phone number.

Only worry about the following format: (123) 456-7890 (don't forget the space after the close parentheses)

Examples:

validPhoneNumber("(123) 456-7890") => returns true validPhoneNumber("(1111)555 2345") => returns false validPhoneNumber("(098) 123 4567") => returns false

About

This is method that accepts a string, and returns true if it is in the form of a valid phone number.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages