How to set array length for multidimensional static arrays

Namal via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon Feb 1 03:15:40 PST 2016


Sorry guys that I didn't express myself well. I also mixed some 
stuff up. What I wanted to ask is this, in c++ this is valid

	int x = 3;
	int y = 10;
	int arr [x][y];

x,y are known at the compile time and arr is a static array. I 
can't do that in D so what is the best way to declare an array of 
that size?


More information about the Digitalmars-d-learn mailing list