This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
I tried, but it ran well. Except ofcourse, I changed "return 1" to "return 0" (you dont want to return an error from Main)1 #include <stdio.h> 2 int main() 3 { 4 double a[1450][1450]; 5 6 a[1449][0] = 999; 7 printf( "%lf\n", a[1449][0] ); 8 return 1; 9 }
it gives segementation fault
if i use malloc also it gives wrong resultI guess your system is lacking the memory required to allocate 1450 * 1450 * 4 bytes on stack. Try making it static.
what to do?
ankit
________________________________________________________________________
Yahoo! Messenger - Communicate instantly..."Ping" your friends today! Download Messenger Now http://uk.messenger.yahoo.com/download/index.html
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |