什麼是ECDSA?
Herr Deng桑的教學blog
這是Herr Deng桑的教學blog,主要處理作業與班導事務,另外還有數位小品。
herrDeng網內搜尋
自訂搜尋
Ads
3009年5月25日 星期四
2026年4月6日 星期一
C++ unordered set PMR解Leetcode 874 Walking Robot Simulation
C++ unordered set PMR解Leetcode 874 Walking Robot Simulation
解Leetcode 874. Walking Robot Simulation因為constraints,只好用hashmap,C++ unordered_set是知名的慢,加上pmr可以快上幾倍
------
Solving LeetCode 874, Walking Robot Simulation, requires using a hashmap due to constraints. C++'s unordered_set is notoriously slow; adding PMR can speed it up several times.
2026年3月30日 星期一
2026年3月28日 星期六
C++UnionFind與matrix分析解難題Leetcode 2573 Find the String with LCP
解難題Leetcode 2573. Find the String with LCP,其實重點是lcp非常特殊的矩陣,只要搞定lcp各項的關聯,如對稱性,對角線上值-1等特性,應該能解出。會先用Union-Find主要是其解法可針對更為廣義的題目,要快就用貪婪。
2026年3月23日 星期一
2026年2月28日 星期六
Py3 C++位元處理與DP解Leetcode 1680 Concatenation of Consecutive Binary Numbers
Py3 C++位元處理與DP解Leetcode 1680 Concatenation of Consecutive Binary Numbers
這當然不是DP的問題,但透過DP的手法卻可以大幅減少計算時間
----
This is certainly not a problem with dynamic programming (DP), but by using DP techniques, the computation time can be significantly reduced.
2026年2月21日 星期六
C++ Py3 bitmask速解Leetcode 762 Prime Number of Set Bits in Binary Representation
C++ Py3 bitmask速解Leetcode 762 Prime Number of Set Bits in Binary Representation
這段影片示範如何使用計數位元和位元遮罩(bit mask),用幾行程式碼解決這個問題。
-----
this video shows how to use count bits & bitmask to solve this question in few lines.
訂閱:
意見 (Atom)
熱門文章
-
計算你上學期加權平均
-
用 while loop 算 s=3*3+4*4+....88*88
-
輸出課表代碼矩陣 Hint: 2-D array, double-for loop
-
33, 45, 87, 99, 27 算平均
-
請用C/C++ 程式計算 S=1*1+2*2+3*3+4*4+.....+20*20=?
-
產生10個0~99的亂數存在a[10] 中
-
data structure 期中考乙
-
輸出字串20次
-
問int怎麼存-689這個數字。 int用4個bytes。 答案請用16進位表達。
