Looking for a regex for the following
- Should match value before decimal place.(should return
5if value is5.4) - Whole number should be matched as it it (
2in case of2and4in case of4).
The numbers could be 1.2, 2.4, 2.5566, 3.555, 1, 2, 8
Regex should match 1, 2, 2, 3, 1, 2, 8