Xavior2K3
asked on
Array Maximum Bounds - OutOfMemoryError
Hi,
I'm trying to create an array with the following:
int[][] imgArray = new int[3200][4800];
But i get an error:
Exception in thread "main" java.lang.OutOfMemoryError : Java heap space
Why is this and is there any way around it? Are there maximum array bounds?
Thanks,
Michael
I'm trying to create an array with the following:
int[][] imgArray = new int[3200][4800];
But i get an error:
Exception in thread "main" java.lang.OutOfMemoryError
Why is this and is there any way around it? Are there maximum array bounds?
Thanks,
Michael
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Since 3200 * 4800 * 4 (int size) = 58.6 MB
ASKER
Great, thanks =)