I have a variable with the following contents: "a b c d e f g h i j k l", how would you go about adding a comma sign (,) after each third member so it looks like this: "a b c, d e f, g h i, j k l".
Initially all my variable data is stored in an array so if anyone knows how to directly manipulate the array, it would be great.
Thanks in advance
awk