Adding to a vector of pair

后端 未结 10 1429
悲哀的现实
悲哀的现实 2021-01-30 05:19

I have a vector of pair like such:

vector> revenue;

I want to add a string and a doub

10条回答
  •  情话喂你
    2021-01-30 05:57

    Read the following documentation:

    http://cplusplus.com/reference/std/utility/make_pair/

    or

    http://en.cppreference.com/w/cpp/utility/pair/make_pair

    I think that will help. Those sites are good resources for C++, though the latter seems to be the preferred reference these days.

提交回复
热议问题