Q39.webp
F

Q39.webp

  • Media owner Falman97
  • Ngày thêm
Question: 39
(Choose 1 answer)
FJOVERFLOW.COM
How do you correctly overload the + operator for a class Vector in C++?
A. Vector operator+(Vector a, Vector b) {
Vector result;
result.x = a.x + b.x;
result.ya.y + b.y;
return result;
B. void operator+(Vector a, Vector b) {}
C. friend Vector operator+(const Vector &a, const Vector &b);
D. Vector operator+() { /*...*/}

Thông tin

Category
PRF193
Thêm bởi
Falman97
Ngày thêm
Lượt xem
397
Lượt bình luận
3
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom