Leetcode weekly contest 333, problem D

Published --