Yes, that´s right but if you have to perform many operations maybe the "echo" + "bc" form is quite faster:
[EMAIL PROTECTED]:~$ time echo "24 * 365.25" | bc 8766.00 real 0m0.018s user 0m0.002s sys 0m0.001s [EMAIL PROTECTED]:~$ time python -c "x = 24 * 365.25 ; print '%.2f' % x " 8766.00 real 0m0.154s user 0m0.015s sys 0m0.007s [EMAIL PROTECTED]:~$ cat /proc/cpuinfo |egrep "(model name|MHz|cache|bogo)" model name : AMD Athlon(tm) XP 2000+ cpu MHz : 1666.922 cache size : 256 KB bogomips : 3335.59 Best regards, Felix On 9/2/07, Cousin Stanley <[EMAIL PROTECTED]> wrote: > > > > That's still a little bit high, actually: > > > > ~$> echo "24 * 365.25" | bc > > 8766.00 > > > > but I only did this to illustrate the more compact use > > of some system tools, in this case 'echo', 'bc' and a pipe. :) > > G.W. .... > > Python can also be used in a handy and compact form .... > > $ python -c "x = 24 * 365.25 ; print '%.2f' % x " > 8766.00 -- > Stanley C. Kitching > Human Being > Phoenix, Arizona > > > ----== Posted via Newsfeeds.Com - Unlimited-Unrestricted-Secure Usenet > News==---- > http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ > Newsgroups > ----= East and West-Coast Server Farms - Total Privacy via Encryption > =---- > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact > [EMAIL PROTECTED] > >