Memory Estimator
Memory CheckEasyEstimate heap memory footprint of vectors, matrices, and strings to avoid Memory Limit Exceeded (MLE) verdicts.
Alt+Shift+8
Configuration Panel
Memory Footprint Summary
Estimated Allocation:
Safe Capacity38.1470 MB
0 MBLimit: 256 MB
Total Allocation Bytes:40,000,024 bytes
Structure Layout:vector<int>
Example Test Cases
10^7 integers in a flat vector
Input 1:vector;int;10000000
Output:~38.15 MB
Load Case
1000x1000 grid table
Input 1:matrix;int;1000;1000
Output:~3.84 MB
Load Case
5*10^7 long long values
Input 1:vector;longlong;50000000
Output:~381.47 MB (exceeds 256MB)
Load Case
Notes & Tips
- Typical competitive programming memory constraints are 256MB or 512MB.
- A flat 1D vector of $10^7$ standard 4-byte integers consumes approximately 38.15MB.
- Nested structures (e.g. `vector<vector<int>>`) add heap pointer overheads (~24 bytes per row).