std::string& str_toupper(std::string& s) {
    std::transform(s.begin(), s.end(), s.begin(), 
                   [](unsigned char c){ return ::toupper(c); } // correct
                  );
    return s;
}

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-08-22
  • 2021-07-10
  • 2021-08-06
  • 2021-07-09
  • 2021-12-16
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-12
相关资源
相似解决方案