CPP
cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <iostream>
#include <vector>
#include <string>
using namespace std;
int main() {
// sizeof(std::string) * (2^42)
const unsigned long long Size =
sizeof(string)
* (1UL << 42UL);
cout << Size << endl;
char* s = new char[Size];
delete[] s;
return 0;
}
Enter to Rename, Shift+Enter to Preview
OUTPUT
Run