How many bytes of memory is allocated when you declare: double* p1[10];

Recommended Answers

All 3 Replies

At a minimum, 10xsizeof(double*). The size of a pointer depends upon whether you are running in 32-bit or 64-bit mode. The easy way to tell is to execute the function/macro sizeof(p1).

Thanks! I figured it out.

function/macro sizeof(p1)

sizeof is not a function or a macro it is an operator.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.