05 2019 档案

[Leetcode] Integer to Roman
摘要:數字轉羅馬文字,4 & 9 有特例 ,除 千 百 十 及餘 取係數出來,如果係數== 9 or 4 就固定某個roman number,不是就 repeat 係數/5的次數 及 repeate 係數% 5的次數,全部加起來就是了 阅读全文

posted @ 2019-05-28 14:27 seako 阅读(159) 评论(0) 推荐(0)

[Leetcode] Find Peak Element
摘要:找出一個大於兩邊的頂點,可以把nums[-1] ,nums[n] 都視為負無限 因為我用 int.minvalue來代表 num[-1] 及 num[n]的值 所以leetcode的test case 有一個測試是 [-2147483648] ,用來坑minvalue的 阅读全文

posted @ 2019-05-19 22:59 seako 阅读(124) 评论(0) 推荐(0)

[Leetcode] Binary Tree Pruning
摘要:題目是說,如果左右子樹都不存在又自已為0,就去掉那個子樹(設為null) recursive後序,左子樹,右子樹,然後是根 自已同時又是別人的子樹,所以要告訢根自已是不是存在 從a開始,左右子樹都不存在,而自已是1 所以傳回true 告訢 root(c) 左子樹a 不可以刪掉(存在) b,左右子樹都 阅读全文

posted @ 2019-05-15 02:01 seako 阅读(145) 评论(0) 推荐(0)

[個人紀錄] windows form , usercontrol design 模式不見
摘要:windows form 跟 usercontrol 都變成cs檔 無法點擊進入設計模式 <Compile Include="Form1.cs"/> <Compile Include="Form1.Designer.cs"> <DependentUpon>Form1.cs</DependentUpo 阅读全文

posted @ 2019-05-10 19:24 seako 阅读(281) 评论(0) 推荐(0)