| Raw Input
| john acct 33425 NewYork
mary sale 184523 Taipei
kelly mis 4538 HongKong
|
|
| Desired Output
| john acct 0033425 NewYork
mary sale 0184523 Taipei
kelly mis 0004538 HongKong
|
|
Script and Comments
Script1 [ 1] s/[^ ][^ ]*/\n000000&/3
[ 2] s/\n[^ ]*\([^ ]\{7\}\)/\1/
| |
|