Skip to content

Instantly share code, notes, and snippets.

Created July 29, 2013 17:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/6105923 to your computer and use it in GitHub Desktop.
Save anonymous/6105923 to your computer and use it in GitHub Desktop.
//An istream is passed in to the function as an argument so we don't need to worry about generating it. Referred to by "in".
string line; char key; string value; istringstream iss;
while (in.good()) {
getline(in,line);
iss.str(line);
iss >> key;
iss >> value;
codeMap[key] = value;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment