Created
September 22, 2009 04:47
-
-
Save marksands/190821 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string> | |
inline std::istream& operator >>(std::ostream& os, std::string &arg) { return (std::cin >> arg); } | |
inline std::ostream& operator <<(std::istream& is, std::ostream& (*_T)(std::ostream&)){ return (std::cout << _T); } | |
int main() | |
{ | |
std::string name; | |
std::cout << "Name? " >> name << std::endl; | |
std::cout << "Hello, " << name << std::endl; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment