bool check_size(string s, int sz)
{
    return s.size() >= sz;
}

int main() {
    vector<string> strs = { "axx", "css", "bww", "ssdde", "awweerf" };
    int sz = 4;
    auto f1 = bind(check_size, placeholders::_1, placeholders::_2);
    auto wc = find_if(strs.begin(), strs.end(), bind(check_size, placeholders::_1, sz));
    cout << *wc;
    return 0;
}

 

相关文章:

  • 2021-08-06
  • 2022-02-15
  • 2021-11-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-16
  • 2022-12-23
猜你喜欢
  • 2021-05-15
  • 2022-12-23
  • 2021-05-30
  • 2021-08-26
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案