The following code allocates a 10 element array of pointers to doubles.
int i=0;
double* dp[10];
for (int i = 0; i < 10; ++i)
{
*(dp[i]) = 0.0;
}
for (int i = 0; i < 10; ++i)
{
cout<< *dp[i]<< endl;
}
Now how do I initialize each of these doubles to 0.0.