Fish Wang says to YSITD
複雜度O(m+n)