I have a vector of a structure called ParsedFlag
;
struct ParsedFlag {
std::string flag, value;
ParsedFlag init(std::string f, std::string v)
{
flag = f;
value = v;
return *this;
}
}
Now, I have duplicate entries, which look like this:
(gay, yes)
(verbose, haha ok)
(desc, yeah okay)
(desc, yeah okay)
(a, 2)
(a, 2)
(c, c)
(f, f)
(g, 1)
(a, a)
(b, b)
(c, 1)
and my goal is to remove all of the duplicates of already existing ones: (desc, yeah okay)
, (a, 2)
.
How can I do this?