I ask:
#include <string.h>
using namespace std;
int main()
{
unsigned char file[512000];
unsigned char key[512000];
for(int i = 0; i < 512000; i++)
file[i] = key[i];
return 0;
}
When I compile this with cl.exe on Windows, I get an executable file about 31 KB in size. The buffers themselves are 500 kb. How does that make sense? Will part of it be allocated to a bunch? If I initialized them with data, would the size be correct?
source
share