cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
Beginners
question
question
Apr 20, 2011 at 1:41am UTC
khaled
(1)
i create a vector and i have access an element which is not in the vector's range but it's a must
Apr 20, 2011 at 3:16am UTC
Zhuge
(4664)
I'm not sure I understand what you are trying to say, but...
A vector is like an array. It's a contiguous list of elements; you can't just access arbitrary spots. Maybe you could use a different container, like a map of ints?
Topic archived. No new replies allowed.