16 May 15:45
Re: How to use arrays efficiently?
Lauri Oksanen <lassoken <at> gmail.com>
2008-05-16 13:45:50 GMT
2008-05-16 13:45:50 GMT
Yes, of course. How blind of me. Here is one more question.
If you change IOUArray to IOArray and add $! in front of the two summations in the previous code, it still works correctly.
But can you do similar trick with Array and accumArray? I have tried to put $! in different places in the first code that I posted but nothing seems to work.
On Fri, May 16, 2008 at 4:26 PM, Henning Thielemann <lemming <at> henning-thielemann.de> wrote:
Maybe an (UArray (Int,Int) Double) could help, where the second index range is fixed to (0,2).
On Fri, 16 May 2008, Lauri Oksanen wrote:Thanks for help. I did some tests with UArray and it does the trick.
The problem remaining is, how to implement UArray Int (Double, Double, Double)?
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe <at> haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
RSS Feed