#!/bin/bash

echo -e "iTest\ttaille\ttri\ttemps\tmem"

for iTest in `seq 1 10`
do
    taille=$(( `od -An -N4 -tu < /dev/urandom` % 10000000))

    for tri in "fusion" "insertion" "rapide"
    do
        `( ./tri -g $tri $taille ) > tabs/$tri.txt`
        res=`( time  "%U\t%M" ./tri --$tri tabs/$tri.txt > /dev/null ) 2>&1`
        echo -e "$iTest\t$taille\t$tri\t$res"
    done
done