Koios @ Sprout 2022
lower_bound 和 upper_bound
跟 sort 一樣
可以加上自訂的 cmp 函數!
下例中,我們利用模 3 的餘數大小作為排序方式,如果一樣大才比較真實大小
Koios @ Sprout 2022
Special Thanks : Wu-Jun Pei @ Sprout 2021
第一支程式
輸入輸出
if/else
迴圈(for loop、while loop)
陣列(一維、多維)
字元、C-style 字串
Function
指標
struct
Header Files & Template
C++ string
C++ File I/O
Class
new / delete
STL
複雜度
排序、二分搜
遞迴