Advertisement
8877omega_java

Untitled

Oct 8th, 2015
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.63 KB | None | 0 0
  1. <source lang="cpp">
  2.  
  3. include <iostream>
  4. template<char O, bool =O == 'h'? '-' :O == 'w'? '=' :0>class _;
  5.  
  6. template<char O>std::ostream&operator<<(std::ostream&lhs,_<O,0>*) { return lhs << O; }
  7.  
  8. template<char O>std::ostream&operator<<(std::ostream&lhs, _<(O), 'o'>*) { return lhs<<(char)(O - '!' + '.' - '-' ); }
  9.  
  10. template<> std::ostream&operator<<<'~'>(std::ostream& m9,_<'~', 'o'>*) { return m9<<('m'); }
  11.  
  12. int main(int orz=3) { std::cout<<(_<'h'>*)0<<(_<'e'>*)0<<(_<'l'>*)0<<(_<'l'>*)0<<(_<'o'>*)0<<(_<'w',0>*)0<<(_<' '>*)0<<(_<'w'>*)0<<(_<'o'>*)0<<(_<'r'>*)0<<(_<'l'>*)0<<(_<'d'>*)0<<(_<'!'>*)0<<std::endl; return 0; } </source>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement