摘要:
O(1)的字符频度匹配 设计一个 distance数组记录 s字串和 t的匹配程度。也就是每个字符频度的差 s[c] - t[c] = distance[c] t初始化distance中个字符的频度,如果s[c] 统计到一个,就在distance--,这样,当distance为0时,就代表这个字符完 阅读全文
posted @ 2025-03-25 21:30
丘狸尾
阅读(17)
评论(0)
推荐(0)
摘要:
```C typedef struct Node { int num; // 值 int index; // 原数组索引 int size; // 逆序对数量 } Node; class Solution { public: void mergeSort(vector<Node> &arr, int 阅读全文
posted @ 2025-03-25 12:39
丘狸尾
阅读(9)
评论(0)
推荐(0)

浙公网安备 33010602011771号