Your copy constructors are wrong. You are copying to the source rather than destination. Try replacing:
base(base &a)
{
cout<<"base Copy Constructor\n";
a.i=i;
}
With:
base(base &a)
{
cout<<"base Copy Constructor\n";
i = a.i;
}
AND
derived(derived &a)
{
cout<<"derived Copy Constructor\n";
a.j=j;
cout<<j<<endl;
}
with
derived(derived &a)
{
cout<<"derived Copy Constructor\n";
j=a.j;
cout<<j<<endl;
}