Search Results

Search: Posts Made By: f77coder
3,374
Posted By junior-helper
No, the for loop goes through the array and...
No, the for loop goes through the array and passes the values one by one - placed in the $i variable - to sed.
sed does the text transformation part only.

---------- Post updated at 11:29 PM...
3,374
Posted By Scrutinizer
These two suggestions work in a similar way: ...
These two suggestions work in a similar way:
sed "s/^$i.*/$i , $ratio/"
and
sed "s/^$i *,.*/$i , $ratio/"
There is a difference however:

The second form uses the comma as a kind of "anchor"...
Showing results 1 to 2 of 2

 
All times are GMT -4. The time now is 09:47 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy