RE: $100 Contest Question
- Posted by bensler at mail.com
Mar 03, 2002
What kind of bench test are you using Derek? I get nowhere near those
kinds of results.
what is your average iteration time?
I use..
match_pattern({1,2,3,1,4,3,3,2,5,3}) -- ZIGZAGGING
..in an iterated loop
I don't think I can even iterate 50x in 1.48 seconds
And that pattern is on the faster side of the avergage.
I don't understand how you could possibly get it that fast, unless your
pattern is {1}, only then is my program comparable to your results.
I've still got some tweaking to do, but I don't see it getting much
faster.
Try...
-- find all 7 letter words with unique letters
match_pattern({1,2,3,4,5,6,7})
I'd like to know what your iteration time is for that one.
Chris
Derek Parnell wrote:
> ----- Original Message -----
> From: "Kat" <gertie at PELL.NET>
> To: "EUforum" <EUforum at topica.com>
> Sent: Monday, March 04, 2002 7:38 AM
> Subject: Re: $100 Contest Question
>
>
> > > if a '-' or '\'' is supplied (or some character greater than ASCII 32),
> > > it should be treated as a literal character to be matched. Values
> > > from 0 to 32 represent "meta" characters, or placeholders for
> > > unspecified characters in the pattern. I'll only give you upper case
> > > literal characters, A, B, C, ...
> >
> > So the input file will be all upper()'d already?
>
> Here, Robert is only talking about the characters in the pattern text
> used
> to test comp#2. Not the word list or any file used in any competition.
> If I
> was you, I'd expect mixed case text for the input files in comp#1 and
> comp#3.
>
>
> > Robert Craig wrote:
> > > In problem #2, assume that I will make 1000
> > > calls to your function.
> >
> > You realise, at 5 minutes runtime per iteration, that's 83 hours? If you
> get
> > 100 such entries, that's 345 DAYS of runtime for testing problem #2
> > programs.
>
> There is something really wrong if a single iteration takes that long.
> I'm
> sure Robert will pull the plug on any program runs longer than 5
> minutes.
> Currently I'm doing 1280 iterations in 1.48 seconds, and I haven't
> finished
> optimising it yet.
>
> > Robert Craig wrote:
> > > I'm planning to run each program once,
> > > with a few megabytes of input text.
> >
> > *megabytes*? of the same few sentences repeated ad naseum, with
> > different
> > keys? Or will you be feeding it a online book text with unique sentences
> and
> > the same key for all sentences?
>
> In comp#1, we are required to *encipher* some English text. As a trial,
> I
> combined all the Euphoria\DOC files in to a single file then copied that
> file to itself a few times until I had a file that was 4,267,462 bytes
> long.
> My program takes about 4 seconds to encipher this file.
>
> --------
> Derek
>
>
|
Not Categorized, Please Help
|
|