(Feb-24-2021, 11:01 AM)Serafim Wrote: I didn't answer your last question (3):
I think normalize is the place. Add one digit to the decimals and then shorten the result. It's a messy business as the result is actually a string. Maybe consider the two last digits as a decimal number and round it of as an integer. Then replacing the two last digits in the result string by that integer.
E.g. the last two digits = '37' => 3.7 => rounded to 4 and replace '37' by '4'.
Maybe there are other ways.
Very bold answer as never got this detail printed anywhere on SO. Seems they want reader to figure it out. But came only near to this idea.
But, still (after your answer) feel to comprehend fully need code or at least elaborate algorithm.
Thanks in anticipation.