#include <iostream>
class IA
{
};
class IB : public IA
{
};
class B : public IB
{
};
class IX
{
public:
virtual void x(IA*) = 0;
};
class X : public IX
{
public:
virtual void x(IA*)
{
std::cout << "ok\n";
}
};
int main()
{
B b;
X x;
x.x(&b);
}
I2luY2x1ZGUgPGlvc3RyZWFtPgoKY2xhc3MgSUEKewp9OwoKY2xhc3MgSUIgOiBwdWJsaWMgSUEKewp9OwoKY2xhc3MgQiA6IHB1YmxpYyBJQgp7Cn07CgpjbGFzcyBJWAp7CnB1YmxpYzoKICAgIHZpcnR1YWwgdm9pZCB4KElBKikgPSAwOwp9OwoKCmNsYXNzIFggOiBwdWJsaWMgSVgKewpwdWJsaWM6CiAgICB2aXJ0dWFsIHZvaWQgeChJQSopCiAgICB7CiAgICAgICAgc3RkOjpjb3V0IDw8ICJva1xuIjsKICAgIH0KfTsKCmludCBtYWluKCkKewogICAgQiBiOwogICAgWCB4OwogICAgeC54KCZiKTsKfQ==