I am trying to place a different sting at the end of each line using. The below works but not when the file is large. x=line # in the file. The data goes to the end with $.Let data=0Let x=0 while [ $data -lt 10 ] do data=$(($data+1)) x=$(($x+11)) sed  -i  ''$x's/$/ '$data' /' file.doneWhat I am trying to do.Before:file_nameabc abc abc abc abc abc abc abc abc After:file_name abc abc abc 1 abc abc abc 2 abc abc abc 3 etc...
Using Sed or awk to put a string at the end of a line
sed