Ok I don't really understand. Almost whenever I write a program that requires user input I get this error saying the program caused an error in MSVCRT.DLL and will now close. From previous experience, that is a memory error because of some memory issues. But the type of information the program is storing when it hits the error is int. Is it necessary to "allocate" memory for a int type too!? If someone could please explain this to me that would be a great help. Also, when storing a string, what is better to use? An array like this:
or a pointer like this:Code:char array[5000];
array[5000] = "This is a string";
Thanks a bunch.Code:char *pointer;
pointer = (char*)malloc(5000);
pointer = "This is a pointer";