Question: One variation in how we write down US phone numbers is that we sometimes leave off the parentheses around the area code and instead use

One variation in how we write down US phone numbers is that we sometimes leave off the parentheses around the area code and instead use a dash after it: 757-555-0000 for example.
Many businesses have adopted the practice of using "."(period) instead of "-"(dash) between the number groups: 757.555.0000 for example.
By convention, international telephone numbers begin with a plus sign (+) followed by a 1,2, or 3-digit country code. The US country code is "1". So the example US phone number would be written as +1757.555.0000 in this international style.
THE CHALLENGE
1. Write down a BNF grammar and State Diagram for US phone numbers that uses the star (*) after the area code instead of parentheses around it.
2. Write down a BNF grammar and State Diagram for US phone number written in the international style.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!