Originally posted by nickyeng
class to hold 2 double values representing the x and y coordinates
Collapse
X
-
Originally posted by horace1I would have thought a vector would have two Points for the vector start and end or does Vector mean something else in this context?
actually the answer wont be the compiled-well code. What to do is just write the code for each questions. Forget it about compiled-well mind..!
i'm not sure my code is correct, and there is no other ppl here can provide me with the better one, so i just follow my code.
thanks for the help anyway.Comment
-
Originally posted by nickyengvector class is unrelated to STL vector. It just a simple class.
thanks for the help anyway.
I am not sure what you mean by a vector?Comment
-
Originally posted by horace1I am not talking about STL vectors but about a vector in 2D coordinate space - one would have a x1, y1 start Point and a x2, y2 end Point
I am note what you mean by a vector?
forget about this question.
End of thread.Comment
-
Vectors in the mathematical sense have an origin (x,y) a direction (maybe a slope or something to that effect) and a magnitude. You can give the origin and another point in the line of the vector and a magnitude but you can choose any other point on the vector line. Vectors don't have end points, they are rays of a certain magnitude.Comment
Comment