s/\t(?=\t)/\t0/g
Unfortunately, that regex doesn't work with other of the OPed example data strings that have leading and/or trailing tabs, e.g., "4\t4\t4\t\t\t4\t\t\t\t3\t" and "\t\t4\t4\t\t\t1\t\t\t\t". (It took me a while, but I finally figured out that all that whitespace was due to tab characters. I suspect that yueli711 changed the posted example data, too. Oh, well... :)
Give a man a fish: <%-{-{-{-<
In reply to Re^2: substitute space to 0
by AnomalousMonk
in thread substitute space to 0
by yueli711
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |