Python Solution For UVa Online Judge: 325 - Identifying Legal Pascal Real Constants
P325.py, Python Solution of UVa string-processing problem: 325 - Identifying Legal Pascal Real Constants. In this post we will see how we can solve this challenge in Python for UVa Online Judge.
Pascal requires that real constants have either a decimal point, or an exponent (starting with the letter e or E, and officially called a scale factor), or both, in addition to the usual collection of decimal digits. If a decimal point is included it must have at least one decimal digit on each side of it. As expected, a sign (+ or -) may precede the entire number, or the exponent, or both. Expone...
You can find the full details of the problem Identifying Legal Pascal Real Constants at UVa Online Judge
Solution: Please check the p325.py snippet for the solution.
Solution originally posted at: Github by @sajjadt