![]() |
Maximum char array size Hello I am trying to declare a char array of size of approximately nineteen million of positions and I am receiving a Segmentation fault when running my program. The declaration is the last thing of the program. So what it is the maximum size I can use? Should I use dynamic memory allocation? Or maybe a vector? In this case what is the better option. I know in advance the size of the array, that's why I tried to use one and not a vector. EDIT: I made I mistake, I only needed an array of 1/8 that size, and it worked just fine with this new size. But for future use, my question is the same. What is it the maximum size, should I use dynamic memory or a vector? |
| All times are GMT -6. The time now is 04:25 PM. |