Article View: pl.comp.lang.tcl
Article #236Re: Optymalizacja skryptu
From: Googie
Date: Wed, 28 Dec 2005 08:42
Date: Wed, 28 Dec 2005 08:42
34 lines
1532 bytes
1532 bytes
Derek Kuliński / takeda wrote:
> Najbardziej nie podoba mi się procedura calculate_timer_value, ale jeżeli
> ktoś ma pomysły jak poprawić inne części to też będzie to mile widziane =)
Może tak:
proc calculate_timer_value {time_left} {
foreach {v1 v2} {
86400 86400
72000 14400
1800 1800
900 900
300 300
60 60
30 30
15 15
5 5
0 1
} {
if {$time_left > $v1} {
return $v2
}
}
return 0
}
> Przy okazji chciałbym życzyć Wam wszystkiego najlepszego z okazji
> zbliżającego się Nowego Roku :)
A dziękuję, dziękuję, wzajemnie :)
--
Pozdrawiam!
Googie
Technical Details
Message-ID:
<dotin8$ub2$1@srv.cyf-kr.edu.pl>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!mat.uni.torun.pl!news.man.torun.pl!newsfeed.pionier.net.pl!news.nask.pl!news.nask.org.pl!news.cyf-kr.edu.pl!not-for-mailReferences:
<spguu0moj949$.dlg@takeda.tk.invalid>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!mat.uni.torun.pl!news.man.torun.pl!newsfeed.pionier.net.pl!news.nask.pl!news.nask.org.pl!news.cyf-kr.edu.pl!not-for-mail From: Googie <no@spam.org> Newsgroups: pl.comp.lang.tcl Subject: Re: Optymalizacja skryptu Date: Wed, 28 Dec 2005 09:42:45 +0100 Organization: Academic Computer Center CYFRONET AGH Lines: 34 Message-ID: <dotin8$ub2$1@srv.cyf-kr.edu.pl> References: <spguu0moj949$.dlg@takeda.tk.invalid> NNTP-Posting-Host: ip-7-197.ists.pl Mime-Version: 1.0 X-Trace: srv.cyf-kr.edu.pl 1135758888 31074 193.25.7.197 (28 Dec 2005 08:34:48 GMT) X-Complaints-To: news@cyf-kr.edu.pl NNTP-Posting-Date: Wed, 28 Dec 2005 08:34:48 +0000 (UTC) User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: en-us, en In-Reply-To: <spguu0moj949$.dlg@takeda.tk.invalid> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit