I have two for loops here
for i in $(cat "firstFile.txt")
do
for j in $(cat "secondFile.txt")
do
if [ "$i" = "$j" ]; then
echo $i[$2] # use first file second column
fi
done
done
and I compare strings and if they are the same i want to echo $i[$2] print firstFile.txt second column. Is it possible to do that?