Thanks Paul and Chet;

They both do the same thing and that's exactly what I was looking for.

Thanks again,

Matthew.


Chet Ramey wrote:
> 
> Paul Jarc wrote:
> 
>> date1=`perl -e 'print time()'`
>> ...
>> date2=`perl -e 'print time()'`
>> interval=`expr "$date2" - "$date1"`
> 
> This general approach can be used without invoking any external programs:
> 
> date1=$SECONDS
> ...
> date2=$SECONDS
> interval=$(( $date2 - $date1 ))
> 
> Chet
> -- 
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                      Live Strong.  No day but today.
> Chet Ramey, ITS, CWRU    [EMAIL PROTECTED]   
> http://cnswww.cns.cwru.edu/~chet/
> 
> 
> _______________________________________________
> Bug-bash mailing list
> Bug-bash@gnu.org
> http://lists.gnu.org/mailman/listinfo/bug-bash
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Timing-an-operation-tf3809131.html#a10799786
Sent from the Gnu - Bash mailing list archive at Nabble.com.



_______________________________________________
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash

Reply via email to