$i is not working... it's making me crazy!
for i in {1..200};
do echo "/scratch/inputTest/prob/timit.test.pg.list_10_$i_prob.bin" >> longProbList;
done
in the file there is just
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
/scratch/inputTest/prob/timit.test.pg.list_10_.bin
It thinks your variable name is $i_prob
since an underscore is a valid character for a variable name. Use ${i}
to fix this:
for i in {1..200};
do echo "/scratch/inputTest/prob/timit.test.pg.list_10_${i}_prob.bin" >> longProbList;
done
You've forgotten the " " around $i
for i in {1..200};
do echo "/scratch/inputTest/prob/timit.test.pg.list_10_"$i"_prob.bin" >> longProbList;
done
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With