Why the problem fit for visitor pattern ?

Thanks.