Skip to content

Instantly share code, notes, and snippets.

@elleryq
Created July 7, 2014 03:21
Show Gist options
  • Save elleryq/570b68d4282589cb019a to your computer and use it in GitHub Desktop.
Save elleryq/570b68d4282589cb019a to your computer and use it in GitHub Desktop.
Upper a string in C++
#include <string>
#inculde <sstream>
std::string toupper(std::string& s) {
for(std::string::iterator c=s.begin(); c!=s.end(); c++) {
*c = std::toupper(*c);
}
return s;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment