Article View: pl.comp.lang.javascript
Article #10213Re: szkolka
From: Krzyszt_off
Date: Fri, 17 Jan 2003 12:32
Date: Fri, 17 Jan 2003 12:32
9 lines
1228 bytes
1228 bytes
> > function Digit(a){return
> a=='I'?1:a=='V'?5:a=='X'?10:a=='L'?50:a=='C'?100:a=='D'?500:a=='M'?1000:0}
function Digit(a){return[1,5,10,50,100,500,1000]['IVXLCDM'.indexOf(a)]}
Wprawdzie nie algorytmicznie (no bo nie bede kopiowal Twojego kodu),
ale troche sie poprawilem :)
Krzysiek
Technical Details
Message-ID:
<b08ss7$np3$1@news.tpi.pl>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!news.atman.pl!newsfeed.gazeta.pl!newsfeed.tpinternet.pl!news.tpi.pl!not-for-mailReferences:
<b06bao$cp7$1@news.tpi.pl> <b06hbj$jbk$1@news.tpi.pl> <b0700o$83b$1@news.tpi.pl>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!news.atman.pl!newsfeed.gazeta.pl!newsfeed.tpinternet.pl!news.tpi.pl!not-for-mail From: "Krzyszt_off" <leszek.miller@grube.ryby.pl> Newsgroups: pl.comp.lang.javascript Subject: Re: szkolka Date: Fri, 17 Jan 2003 13:32:50 +0100 Organization: tp.internet - http://www.tpi.pl/ Lines: 11 Message-ID: <b08ss7$np3$1@news.tpi.pl> References: <b06bao$cp7$1@news.tpi.pl> <b06hbj$jbk$1@news.tpi.pl> <b0700o$83b$1@news.tpi.pl> NNTP-Posting-Host: kalmar.mila.edu.pl X-Trace: news.tpi.pl 1042806472 24355 195.116.40.8 (17 Jan 2003 12:27:52 GMT) X-Complaints-To: usenet@tpi.pl NNTP-Posting-Date: Fri, 17 Jan 2003 12:27:52 +0000 (UTC) X-Newsreader: Microsoft Outlook Express 5.00.2919.6700 X-MSMail-Priority: Normal X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit