Browsed by
作者:natetang

2015-09:Longest Increasing Subsequence

2015-09:Longest Increasing Subsequence

 

# UVa 10042 Smith Numbers

# UVa 10042 Smith Numbers

建質數表 然後作質因數分解

參考

Recursion and Mod [2015-02]

Recursion and Mod [2015-02]

這題與 big mod 有點像 都必須用遞迴方式去求 時間才不會超過  

&nbsp…

Read More Read More

#UVA 1210 Sum of Consecutive Prime Numbers

#UVA 1210 Sum of Consecutive Prime Numbers

先建立質數表 在暴力法把每個質數可加到的數暴力法加

 

#UVA 10107 What is the median

#UVA 10107 What is the median

就一直維持陣列為小到大  或是 大到小即可 簡單地計算中位數