Question: Regular Homework: Define a decimal literal to be a string of characters such that a) all its characters are digits or a decimal point b)

Regular Homework: Define a decimal literal to be a string of characters such that a) all its characters are digits or a decimal point b) there are at least two places to the right of the decimal point. c) there is a least one place to the left of the decimal point. d) there is no leading zero (except if it is just before the decimal point. Yes examples: 2.345 0.23 2.0000 20000.00 No examples 02.345 .23 $2.34 98.6 6923.12E5 and also [ ] for equivalence 1) Give a regular expression that accepts this language. You may use () * classes. Don't use any regex extensions (such as ? or \d)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
