I tried to run the code as below and it gets me error: command not found for line 4,5,6. Tried to find similar answers for the questions but I don't know how to figure out the version of the OS of the cluster which Im running this script. Im not sure is there any problem with the first line or the line 4,5,6. Could anyone help?
#!/bin/bash
for i in 02 03 04 05 06 07 09 10 11 12 13 14 15 16 17 20 21 22 23 24 25; do
x=grep $i sphnum.txt |cut -c5-6
y=grep $i sphnum.txt |cut -c8-9
z=echo $i'.ala.'$x'.sph '$i'.ala.'$y'.sph'
echo $z
done