/* 自定義代碼塊樣式 */
Herr Deng桑的教學blog
這是Herr Deng桑的教學blog,主要處理作業與班導事務,另外還有數位小品。
網頁
首頁
密碼學
程式設計Programming
APP
計算機概論
herrDeng網內搜尋
自訂搜尋
Ads
2024年7月26日 星期五
C++Floyd Warshall解Leetcode 1334 Find the City With the Smallest Number ...
C++Floyd Warshall解Leetcode 1334 Find the City With the Smallest Number of Neighbors at a Threshold
由於每對 (i, j) 都有許多最短路徑需要計算,採用 Floyd-Warshall 演算法比較划算。
---
按我讀文 »
2024年7月24日 星期三
Python C++速解排序問題Leetcode 2191 Sort the Jumbled Numbers
今日Leetcode的排序問題2191. Sort the Jumbled Numbers,主要有兩個部份,一個是把數字轉成另一個數字,用int就行,採Least Significant Digit First。然後排序,不建議用自訂Lambda,跑能過但非常慢;更不建議自製車輪去排序。比較快的方式是sort ((mapping(x), index),然後再從排序後的資料中取得 x
[Python code請進]
按我讀文 »
較新的文章
較舊的文章
首頁
訂閱:
意見 (Atom)
熱門文章
計算你上學期加權平均
計算你上學期加權平均
用 while loop
用 while loop 算 s=3*3+4*4+....88*88
ex. SHA-256, SHA3-256, RIPEMD-160
請問"虛擬貨幣用的雜湊函數"的SHA-256, SHA3-256, RIPEMD-160的雜湊摘要值
簡易程式2(平方和)
請用C/C++ 程式計算 S=1*1+2*2+3*3+4*4+.....+20*20=?
輸出課表代碼矩陣
輸出課表代碼矩陣 Hint: 2-D array, double-for loop
輸出字串20次
輸出字串20次
data structure 期中考乙
data structure 期中考乙
ex6 請簡易說明Bitmap, Sleep的使用方式
請簡易說明Bitmap, Sleep的使用方式 請參考 https://anwendeng.blogspot.com/2020/03/visual-studio-2019-cwindows-formbitmap.html https://anwendeng.blogsp...
產生 亂數
產生10個0~99的亂數存在a[10] 中
ex1算平均
33, 45, 87, 99, 27 算平均