原创 TridTree
參考了人家的代碼,還是寫轉載吧。#include<iostream> #include<cstring> #define num_chars 26 //只能插入英文字母 using namespace std; class Trid_no
原创 AVL樹
//修改自《算法之美》,更易理解(自認爲) #include<iostream> using namespace std; template <class T> class AvlTree; template <class T> clas
原创 AVL樹前傳
實現插入和記錄平衡因子,不調整。 難點在尾遞歸,可能修改節點平衡因子 #include<iostream> using namespace std; template <class T> class AvlTree; template <
原创 遞歸轉二進制
#include <iostream> using namespace std; void turntobinary(int n); int main() { int n; cin>>n; turntobinary(n);