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6 7 8 9 10 11 12
1 1 3 4 5 6 7 8 9 10 11 12
1 1 1 4 5 6 7 8 9 10 11 12
1 1 1 1 5 6 7 8 9 10 11 12
1 1 1 1 1 6 7 8 9 10 11 12
1 1 1 1 1 1 7 8 9 10 11 12
1 1 1 1 1 1 1 8 9 10 11 12
1 1 1 1 1 1 1 1 9 10 11 12
*/ ,D
2.62528e62
2.62528e62
2.62528e62
BOXES=:<"1 D
<*/*/>BOXES
-----------┐
│2.62528e62│
L-----------
<*/,>BOXES
-----------┐
│2.62528e62│
L-----------
I'm not sure I am understanding what you are trying to do.
Linda
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of William
Tanksley, Jr
Sent: Sunday, May 26, 2013 12:26 PM
To: Programming forum
Subject: Re: [Jprogramming] Fwd: Do "Out of memory" errors vary by J
implementation?
Out of memory errors are notoriously hard to debug; if you need to run this
program on any different data than what you're using now I'd take up the
offer to come up with an alternate approach.
By the way, it's common for different oses to display different behavior
under pressure. Windows fails early; Linux kills random programs later.
Dunno what mac does.
On May 26, 2013 7:26 AM, "Jeremy Smith" <[email protected]>
wrote:
> Hi everyone,
>
> I was trying to take 9 boxes and multiply them all together, storing
> the output in a single box. The first of the 9 boxes contains 12
> numbers, the second contains 11, and so on, so that the output of this
> calculation will be a single box with 12*11*10*9*8*7*6*5*4=79,833,600
numbers.
>
> When I do this on Jgtk701 for Mac, the operation completes
> successfully and requires about 10 seconds. On my windows machine I
> receive an "Out of Memory" error. I'm using exactly the same series of
commands.
>
> Do these errors vary by machine, or operating system? My windows
> laptop has 8GB of RAM compared to my Mac's puny 4GB.
>
> Thanks,
> Jeremy
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm