Finish leetcode_533.