Ecrire une commande transpose.sh qui transpose les lignes/colonnes d'un fichier. On utilise le caractère : pour delimiter les colonnes du fichier. Par exemple : > for x in {a..h}x{1..8} ; do echo -n $x: ; done | sed 's/8:/8\n/g' > /tmp/source > cat /tmp/source ax1:ax2:ax3:ax4:ax5:ax6:ax7:ax8 bx1:bx2:bx3:bx4:bx5:bx6:bx7:bx8 cx1:cx2:cx3:cx4:cx5:cx6:cx7:cx8 dx1:dx2:dx3:dx4:dx5:dx6:dx7:dx8 ex1:ex2:ex3:ex4:ex5:ex6:ex7:ex8 fx1:fx2:fx3:fx4:fx5:fx6:fx7:fx8 gx1:gx2:gx3:gx4:gx5:gx6:gx7:gx8 hx1:hx2:hx3:hx4:hx5:hx6:hx7:hx8 La transposition du fichier est: ax1:bx1:cx1:dx1:ex1:fx1:gx1:hx1 ax2:bx2:cx2:dx2:ex2:fx2:gx2:hx2 ax3:bx3:cx3:dx3:ex3:fx3:gx3:hx3 ax4:bx4:cx4:dx4:ex4:fx4:gx4:hx4 ax5:bx5:cx5:dx5:ex5:fx5:gx5:hx5 ax6:bx6:cx6:dx6:ex6:fx6:gx6:hx6 ax7:bx7:cx7:dx7:ex7:fx7:gx7:hx7 ax8:bx8:cx8:dx8:ex8:fx8:gx8:hx8