help on vectors

I need write a program to perform vector addition but not use the STL vector class and not include extended input validation. The program is to read from cin and do the math. Here is the algorithm I have:

Read in size of vectors and validate
For each element i of vector1
Read in vector1[i]
Likewise read in elements of vector2 and vector3
For each component c of vector
Let result[c] be 0
For each vector v
Increase result[c] by v[c]
Output the result vector

Im unsure of how to even start. I dont know how to code based on the input of the user to determine the size of vectors and to keep reading the component of an unknown sized vector.
Last edited on
Topic archived. No new replies allowed.