Andy Prowl's answer is great but please resist putting "using std::ostream" in a header. If you do this then other compilation units using your header file will also have this namespace 'used' by default and you can get nasty compilation errors with namespace clashes.