adplus-dvertising
frame-decoration

Question

What is the output of this program?
    #include <iostream>
    #include <map> 
    using namespace std;
    int main ()
    {
        multimap<char, int> mymultimap;
        mymultimap.insert(make_pair('x', 100));
        mymultimap.insert(make_pair('y', 200));
        mymultimap.insert(make_pair('y', 350));
        mymultimap.insert(make_pair('z', 500));
        cout << mymultimap.size() << '\n';
        return 0;
    }

a.

1

b.

2

c.

4

d.

3

Answer: (c).4

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. What is the output of this program?