摘要:
基础算法模板 tire树 #版本一: class Tire: def __init__(self): self.tire = [0, {}] def insert(self, word): p = self.tire for char in word: if char not in p[1]: p[ 阅读全文
摘要:
AcWing 周赛14 区间选数 题意 给出两个区间,要求分别输出两个不同的数,且第一个数属于第一个区间,第二个数属于第二个区间 题解 判断区间端点大小输出 c++ #include<bits/stdc++.h> using namespace std; int main() { int T; ci 阅读全文
摘要:
自变量 读写文件 简单的文件写入 Text = 'This is my first test.\n This is next line.\n This is last line' print(test) my_file = open('my file.txt', 'w') my_file.wirte 阅读全文