#include using namespace std; #include "Doughnut.h" template T Max ( const T& a, const T& b) { if ( a < b ) return b; else return a; } int main() { // Compiler generates code based on the argument type cout << Max( 4, 7 ) << endl; cout << Max( string("toby"), string("tobyy" ) ) << endl; cout << ( string("toby") < string("tobyy") ) << endl; Doughnut d1( Doughnut::BostonCream ); Doughnut d2( Doughnut::Jelly ); cout << Max( d1, d2 ) << endl; return 0; }