I read that vectors and arrays are almost the same. Could you explain this to me?
krnekhelesh 16 Junior Poster
Recommended Answers
Jump to Postvectors are much like arrays
#include <vector> int main() { //standard way to create an array int myarray[someconstsize] = { 0 }; //assigns all values to default zero //vector declaration vector<int> myvec;//declares an int type vector //adding data to them myarray[0] = 4; myvec.push_back(4); //adds four to …
Jump to PostI have dev-c++ but I didn't use it because it didn't support graphics
could always work with Visual Studio
i happen to find this environment quite fun and easy to work in.
Jump to PostDev is better for pure c++, VS tends to convolute what is standard c++. Such as when killer typo mistook
for each
As standard c++.
heh it's actually because of a setting in VS which can be turned off to disable ;)
dont try and set the standard …
Jump to Postok what are you two arguing for. I have neither VC++ nor Bloodshed. BORLAND C++ is the best!!
hehehe i think you win :)
look up the sexually transmitted library (STL)
and the namspace std
along with vectors
very good read and you will learn much …
Jump to Postint main() { //////////////////////////////////// // //Fun With Vectors // //////////////////////////////////// //creating vectors //vectors are created like so //vector< datatype > variable name(size) //if the size is not included a vector of zero elements is created //an int vector with size defined vector<int> vec1(10); //an int vector without …
All 23 Replies

iamthwee
krnekhelesh 16 Junior Poster
Killer_Typo 82 Master Poster
iamthwee commented: You explanations are sooo cute! +12

iamthwee
krnekhelesh 16 Junior Poster
Killer_Typo 82 Master Poster

iamthwee
Killer_Typo 82 Master Poster

iamthwee
krnekhelesh 16 Junior Poster
Killer_Typo 82 Master Poster
~s.o.s~ 2,560 Failure as a human Team Colleague Featured Poster

iamthwee
krnekhelesh 16 Junior Poster

iamthwee
krnekhelesh 16 Junior Poster
krnekhelesh 16 Junior Poster
Bench 212 Posting Pro
krnekhelesh 16 Junior Poster
krnekhelesh 16 Junior Poster

iamthwee
Killer_Typo 82 Master Poster
JRM 107 Practically a Master 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.