Question: (d) (10 points) Construct a context-free grammar that could parse student records of the following format: [Ioanna, 99-123456, UNIC111] (Mark, 91-222222, UNIC9992323243] Note that: The

(d) (10 points) Construct a context-free grammar that could parse student records of the following format: [Ioanna, 99-123456, UNIC111] (Mark, 91-222222, UNIC9992323243] Note that: The first name is any sequence of characters, at least one character, no length restriction. The cell phone number starts with 9 and has 8 digits total. A hyphen is present. The ID number starts with UNIC, followed by a sequence of numbers, at least one number, no length restriction. Each student record is enclosed in square brackets. There is at east one student record in the file. . You may use terminal character in your grammar to specify a single character. You may also use terminal digit to specify a single digit
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
