|
From: Alessandro B. <al...@vi...> - 2003-09-21 21:46:27
|
Why when I try to run the following program
int main()
{
int a[1000000];
system("PAUSE");
return 0;
}
I have a fatal error during execution (it seems to happen when the array =
is over 500000)
while the following program
int main()
{
int *a;
a=3D(int *)malloc(1000000);
system("PAUSE");
return 0;
}
works fine?
In the first there is static allocation and in the second I use dynamic =
allocation, but the result should be the same (or not?)
Thanks.
Alessandro |