I have following c++ code. You can see I created a struct with a constructor and a copy constructor. Can someone explain me why copy constructor is being invoked for the first assignment and not for the other 2 assignments?
#include <iostream>
#include <string>
#include <vector>
struct Vertex
{
    float x, y, z;
    Vertex(float x, float y, float z)
        : x(x), y(y), z(z)
    {
        std::cout << "Created Vertex!" << std::endl;
    }
    Vertex(const Vertex& v) // Copy constructor
        : x(v.x), y(v.y), z(v.z)
    {
        std::cout << "Copied!" << std::endl;
    }
};
std::ostream& operator<<(std::ostream& stream, const Vertex& _v) // Overloading operator<<
{
    stream << _v.x << ", " << _v.y << ", " << _v.z;
    return stream;
}
int main()
{
    std::vector<Vertex> vertices;
    vertices.reserve(3); 
    vertices.emplace_back(Vertex(1, 2, 3)); // 1st assignment
    vertices.emplace_back(4, 5, 6);
    vertices.emplace_back(7, 8, 9);
    return 0;
}
 
     
    