Alocating memory depending of a variable value INT variable
Carlos
checoimg at gmail.com
Tue Nov 19 15:16:36 PST 2013
Well in C I just declared an array during execution with an array
with a multiplied variable for the size of the array.
Since I only need two spaces in the array for each line of
process it was multiplied by two.
so it was like this :
scanf("%d", &Num);
int array[Num*2];
When I tried to do this on D, well it says the variable cannot be
read at compile time.
I don't know how the C language implements this but the main
thing is that it does.
So how can I manage memory depending on the user's input in D ?
Thank you for your attention.
More information about the Digitalmars-d-learn
mailing list