Laurent's solution will be suitable for my purposes. I really do need
to stay in the mutable world for this application. The Java code is
already pushing the limits of acceptable computation time.

Just a small question:
What is the best performing mutable box that I can use to hold a
primitive integer?
Laurent uses a local-var.
There's also atoms, refs, arrays ...?

  -Patrick

On May 27, 3:41 pm, Meikel Brandmeyer <m...@kotka.de> wrote:
> Hi,
>
> On Thu, May 27, 2010 at 12:33:20PM -0700, CuppoJava wrote:
> > Your solution is very clear Meikel. I don't have a benchmark. I'm just
> > worried about the overhead of creating seqs. You use two map's and one
> > vector (which each create a seq I think). The array's will be several
> > gigabytes in size so it might build up.
>
> No problem due to laziness. d as well as w will only be traversed once.
>
> > I forgot to mention that documents can only be loaded in one at a
> > time. Loading a new document releases the currently loaded document.
> > So memoize won't quite work. But I can figure out the details myself.
>
> memoize will work as long as d is sorted, ie. your 0 0 0 1 1 1 blocks
> won't repeat eg. like 0 0 1 1 1 0 1 0 2 ...
>
> Sincerely
> Meikel

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to