Georgia Institute of TechnologyYang Chen
Printable Version of this PageHome PageRecent ChangesSearchSign In

Programming

Popen
Function pointer
IP address conversion function
A good link collection

Java Tutorial
Brewing Java: a Tutorial
Functions in ctype.h
usage of vsprintf
difference between strdup() and strdupa()
string class' .c_str() function.

Perl Tutorial
Socket programming
Usage of fork() and shared memory set between process and its offsprings.
compile
make file
simple one
An online calendar by perl

Visual C++ Tricks and Tips
About array size in VC:
In your situtation you might have two solutions:
1) use a gobal variable, or
2) increase the stack size

Global variables are created in the static data area. The space for static data is compiled into the program.Variables in functions are created on the stack. Stack space is created dynamically at runtime. The stack size is limited by some default max value by the compiler but with the proper compile options can be increased. For example, with MS Visual C++ 6.0 the default stack size is 1 MB. This can be increased in the project setttings.

The following program shows the largest arrays I can compile in Visual C++ 6.0 using the default settings. Note that that the global variable can be larger than the one in main. The variable in the main can be made larger if I increase the stack size.

double num1[99558][99558];
int main(int argc, char argv[])
{
double num2[359][359];
return 0;
}

Last modified 6 March 2006 at 1:54 pm by Yang Chen