Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
This test should really have been a part of the sample tests.
tried it as well,
dont know why i still get the error message:
main.cpp:193:9: error: invalid operands to binary expression ('stringstream' (aka 'basic_stringstream') and 'X')
out << X();
~~~ ^ ~~~
/usr/include/c++/v1/ostream:191:20: note: candidate function not viable: no known conversion from 'X' to 'std::__1::basic_ostream &()(std::__1::basic_ostream &)' for 1st argument
basic_ostream& operator<<(basic_ostream& (__pf)(basic_ostream&));
Good Kata. I almost got tripped up at the end, when my code ran successfully with the sample test, but not the final test. Fortunatley I realised that I needed to overload the "<<" operator to allow printing of x without calling the print function (i.e. cout << x() == x.print() )