Test Visitor pattern with simple formula evaluator