Solve ZigZagConversion.