I am goint to create a very large array but have this error when running this code
The running stops at i = 16895 giving
using namespace std;
cout << UINT_MAX << " " << ULLONG_MAX << endl;
cout << pow(pow(24,2),4) << endl;
unsigned long long int n = pow(pow(24,2),4) ;
cout << n << endl;
double * p = new double (pow(pow(24,2),4));
for (unsigned long long int i = 0; i < n; i++)
p[i] = i;
delete  p;
What's the ways to deal with large size array? I am not sure it C++ std library's various containers will work but I guess they might be too slow and not efficient, so it is slightly better to stick to normal array?
Debugger name and version: GNU gdb 6.8-debian
Program received signal SIGSEGV, Segmentation fault.
Thanks for your help!