看板 Grad-ProbAsk 關於我們 聯絡資訊
Show that in a sequence of (n^2 + 1) distinct integers, there is either an increasing subsequence of length n + 1 or a decreasing subsequence of length n + 1. 請問一下,有人可以舉例稍微說明一下嗎?謝謝。這題有解答,但解答有點難懂, 不知道是否有例子可以看呢?謝謝。 n^2 + 1 這地方好難想像哦! 解答上的例子是{1,3,2,4,9,7}怎麼套進n^2+1呢? -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 27.105.52.222
lubu:不知道是不是我理解錯誤給你參考 6個數字 似乎套不進去n^2+1 06/16 21:52
lubu:感覺5個數字比較對@@ n^2+1=5 =>n=2 也就是隨便寫5個數字 06/16 21:53
lubu:至少會有長度2的increasing or decreasing subsequence 06/16 21:54
lubu:可以把sequence擴大成10 則n=3 這樣去看看 06/16 21:55