C++20 sections · 1024 units
Open in Course

Quiz: References

Knowledge check

Check Your Understanding

What happens with: for (auto [x, y] : vec) { x++; } on vector<pair<int,int>>?

  1. A.Increments first element of each pair in vec
  2. B.Increments only the first pair
  3. C.Compilation error
  4. D.Increments a copy, vec stays unchanged
Start the roadmap to answer the quizzes and solve the challenges