What would be the best way to initialize a Multiple array (1,2,3) within an array (1,2,3) within an array(1,2,3)?
Lee Stone
0
Newbie Poster
Recommended Answers
Jump to PostI'm not sure I understand exactly what you're asking, but initialization lists can be nested:
int foo[2][2][3] = { { {1, 2, 3}, {1, 2, 3} }, { {1, 2, 3}, {1, 2, 3} } };
If the values of the array aren't known at compile …
Jump to PostThis being C++, there are ways of doing whatever you're doing that are much easier for you to keep track of and think about. Does it have to be a 3D naked-array of 3D naked-arrays of 3D naked-arrays? If you're actually modellings a groups of somethings, each of which contains …
All 5 Replies
deceptikon
1,790
Code Sniper
Team Colleague
Featured Poster
Moschops
683
Practically a Master Poster
Featured Poster
Lee Stone
0
Newbie Poster
Moschops
683
Practically a Master Poster
Featured Poster
Lee Stone
0
Newbie Poster
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.