I'm using transform and plus() to merge 2 lists and it throws an error that cannot dereference end list iterator. Anyone could please help? Thank you 

```
    list<int> add(const list<int> & data1, const list<int> & data2) noexcept {
    list<int> output;
    if (data1.size() == data2.size())
    {
        transform(data1.begin(), data1.end(), data2.begin(), output.begin(),plus<int>());
        return output;
    }
    return output; 
}

```