Re: Shut down or leave on?
Yes, that´s right but if you have to perform many operations maybe the
"echo" + "bc" form is quite faster:
felix@mateina:~$ time echo "24 * 365.25" | bc
8766.00
real 0m0.018s
user 0m0.002s
sys 0m0.001s
felix@mateina:~$ time python -c "x = 24 * 365.25 ; print '%.2f' % x "
8766.00
real 0m0.154s
user 0m0.015s
sys 0m0.007s
felix@mateina:~$ 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 <cousinstanley@hotmail.com> 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 debian-user-REQUEST@lists.debian.org > with a subject of "unsubscribe". Trouble? Contact > listmaster@lists.debian.org > >
--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Received on Sun Sep 2 11:09:01 2007
This archive was generated by hypermail 2.1.8
: Sun Oct 07 2007 - 03:35:32 EDT
|