摘要:
class StringHash {public: int size; char *array; char *array_forward; unsigned long long* pre_base; unsigned long long* hash_array; unsigned long long 閱讀全文
摘要:
三法則(Rule of Three)在C++里,它是一個以設計的基本原則而制定的定律。它的要求是,假如類有明顯定義下列其中一個成員函數,那么程序員必須寫入其他兩個成員函數到類內,也就是說下列三個成員函數缺一不可:析構函數、復制構造函數、賦值運算符。上述三個函數是特別的成員函數,假如程序員沒有自行定義 閱讀全文
摘要:
lucas定理求大組合數取模板子 #include<bits/stdc++.h> #define fi first #define se second #define io std::ios::sync_with_stdio(false) using namespace std; typedef l 閱讀全文
摘要:
#include <cstdio> #include <iostream> using namespace std; const int N = 1E4 + 10; const int M = 5E4 + 10; struct node { int to, nxt; } e[M]; int head 閱讀全文