Good morning all, I have a series of files in which some lines are text-only and do not matter, and others which look like this:
size=xxxx
These numbers range from single-digit to six digits. What I would like to do is divide every number in the file by 10, with a minimum of 1, and with all remaining whole numbers. Something just as good can be achieved by deleting the last digit in every line which ends with a number of some sort (I can then find and replace those lines which deleted the only digit). So, for instance
size=32451
...
size=9423
...
size=123452
...
size=3
...
size=31
becomes
size=3245
...
size=942
...
size=12345
...
size=1
...
size=3
Is there an easy way to do this?
Thank you