engineering recuitment NIC NIELIT Scientist B 2023 Mock Test Compiler Design Lexical Analysis Regular Expression
Consider the regular expression-token mapping given below:
| Regular Expression | Token |
| a*(a/b)b* | 1 |
| ac* | 2 |
| b(a/c)b | 3 |
What will be the output when the string 'babaccaab' is scanned by the lexical analyzer if the analyzer outputs the token that matches the longest possible prefix?
1
311
2
321
3
123
4
323