Added visitor pattern for Cut, Depth, Median, Print, Total and Visit.