I have a directory with over 100 files that I have a list with a number that goes with each file. I want to run a for loop as such
numPairs="21 57 93... etc"
for filename in /directory/;
do
$filename [numPairs[1]] > newfilename
done;
Is there a way to (say like in js, that's what I'm familiar with) call the numPairs item corresponding with the filename called in the for loop? Or would I be better creating another list with all of the filenames?
$filename [numPairs[1]] > newfilenamenumPairsa string containing numbers delimited by whitespace? I'm also a bit befuddled by your code as it stands; please clarify.