Oct-04-2019, 02:55 PM
(Oct-04-2019, 06:18 AM)newbieAuggie2019 Wrote: it seems a contradiction and an inconsistency
The following approach could cover all cases (e.g where we might not be sure whether the input string has decimal):
int(float("4.5"))
Output:4
A.D.Tejpal