Question: 1 Toy scanner Write a simple program in C++ that receives a single token as input and checks if the received token is a positive
1 Toy scanner Write a simple program in C++ that receives a single token as input and checks
if the received token is a positive integer number if the received token is a punctuation character: +, *, (, ).
You must use regular expressions in contrast to the example in lecture, and check if the input matches the token definitions above.
The output of the program may look like the following:
$ ./main 716235 number
$ ./main ( punc
$ ./main
* punc
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
