#include "iostream"
#include "typeinfo"

using namespace std;

/*!
Generic version that doesn't do anything
*/
template <class... All> class Print {};

/*!
Starts the recursion over given types
*/
template <
	class First,
	class... Rest
> class Print<
	First,
	Rest...
> {
public:
	/*!
	Prints the type First and calls operator() of Print<Rest...>
	*/
	void operator()() {
		cout << typeid(First).name() << " ";
		Print<Rest...>()();
	}
};

/*!
Stops the recursion over type
*/
template <class Last> class Print<Last> {
public:
	/*!
	Prints the type Last
	*/
	void operator()() {
		cout << typeid(Last).name() << endl;
	}
};


//! No docs for inherited stuff!
template <class... All> class Print2 : public Print<All...>{};
