#include <iostream>

struct D{
	int x;
	D(int a):x(a){}
};

struct C{
	D d;
	C(int x=0):d(x){}
	friend C operator+(C a,C b){
		return C{a.d.x+b.d.x};
	}
	friend std::ostream& operator<< (std::ostream &os, const C &x){
		return os<<" C["<<x.d.x<<"]";
	}

};

int main()
{

	C c;
	c = 1 + c;
	std::cout << c;

	return 0;
}
