#include<iostream>using namespace std;
class base{public:virtual void fn(int x){cout<<"in base class,int x="<<x<<endl;}(1)};
class sub:public base{public:virtual void fn(int x){cout<<"in sub class,int x="<<x<<endl;}(2)virtual void fn(double x){cout<<"in sub class,double x="<<x<<endl;}(3)};
...