herrDeng網內搜尋
自訂搜尋
Ads
2023年12月2日 星期六
2023年11月25日 星期六
C++ Python公式推導Prefix sum解Leetcode 1685 Sum of Absolute Differences in a...
C++ Python公式推導Prefix sum解Leetcode 1685 Sum of Absolute Differences in a Sorted Array
對於會用Σ處理公式的,Leetcode 1685. Sum of Absolute Differences in a Sorted Array這應算是Bill Gates口中簡單的數學,
2023年11月22日 星期三
2023年11月20日 星期一
C++ python 迴圈累加解Leetcode垃圾車問題2391 Minimum Amount of Time to Collect Gar...
C++ python 迴圈累加解Leetcode垃圾車問題2391 Minimum Amount of Time to Collect Garbage。Leetcode垃圾車的問題根本是閱讀測驗,
2023年11月19日 星期日
C++頻率分析解Leetcode 1887 Reduction Operations to Make the Array Elements Equal
C++頻率分析解Leetcode 1887 Reduction Operations to Make the Array Elements EqualLeetcode這個週末的兩題都能用frequency count,即所謂的counting sort來解題,如1887. Reduction Operations to Make the Array Elements Equal。因為是線性時間比起官方解答都要快,當然就100趴
2023年11月18日 星期六
2023年11月16日 星期四
2023年11月15日 星期三
2023年11月9日 星期四
C++ python高斯小學公式解Leetcode 1759 Count Number of Homogenous Substrings
C++ python高斯小學公式解Leetcode 1759 Count Number of Homogenous Substrings
高斯小學公式解1+2+...+n=n(n+1)/2 就 O(1)時間,不用它也行改用迴圈需時O(n)。解Leetcode 1759. Count Number of Homogenous Substrings也很好用,O(n)時間,O(1)空間,如果還要優化,就考慮平行化,這裡似乎有難度,空間就多用點。
2023年11月7日 星期二
C++ python prefix Sum與pyplot圖解打怪問題Leetcode 1921 Eliminate Maximum Numb...
C++ python prefix Sum與pyplot圖解打怪問題Leetcode 1921 Eliminate Maximum Number of Monsters
訂閱:
文章 (Atom)
熱門文章
-
計算你上學期加權平均
-
教育部為提昇全民資安素養與電腦防護能力,本部於101年9月5日至11月5日舉辦「全民資安素養自我評量」活動,請在活動期間內踴躍上網檢測資訊安全素養認知程度,並有機會參與抽獎,詳情請參閱活動網站(網址: https://isafe.moe.edu.tw/event
-
算上學期加權平均
-
河內塔程式
-
將費氏數列輸出至一long 陣列 其中f[0]=1, f[1]=2, f[n]=f[n-1]+f[n-2] (n>=2)
-
簡述何謂敘述統計與推論統計? 要瞭解上本課60同學平日平均花在facebook上的時間有多少,隨機抽出20位同學為樣本分析,請問母體為何?研究的變數為何?樣本為何?
-
LinkedList Exercise mm/dd Java 中的 LinkedList mm/dd 列印課表 mm/dd GCD mm/dd Ex2 mm/dd 用Eclipse寫hello.java mm/dd
-
何謂演算法?並列出一無窮迴圈的範例!
-
簡答題: 比較C/C++, Java, VB的差異!

