What can a one-dim array NOT be indexed as.

Dec 15, 2011 at 12:43am
Going over my practice exams for my final....

Which of the following is true....

B) The index type of a one-dim array can be any data type.


B is false, but what data type can a 1 dim array not be? My guess would be something like a string or bool?
Dec 15, 2011 at 1:35am
I believe you can only index an array with an integral type, so an integer or an enum.

And an array can house any data type, even user created types. There is no data type that you can't store in an array that I know of.
Last edited on Dec 15, 2011 at 1:36am
Topic archived. No new replies allowed.