2019.9.25: toolz 是十分便利的工具 学习内容:itertoolz 一、Itertoolz: 1、accumulate(binop, seq, initial): 反复将二进制函数应用于序列,累积结果,返回迭代器 如果有initial,新序列第一个值就是initial,不然就是seq的 ...
分类:
编程语言 时间:
2019-09-26 00:36:06
阅读次数:
157
不难的题目。因为SG性质,所以只需要对一棵树求出。 然后如果发现从上往下DP不太行,所以从下往上DP。 考虑一个点对子树的合并,考虑下一个删的点在哪一个子树,那么剩下的状态实际上就是把一个子树所有能达到的状态异或上一个数。 此时还有不到子树的状态,直接插入子树SG异或值。 所以显然,就是维护一个支持 ...
分类:
其他好文 时间:
2019-09-21 16:54:26
阅读次数:
97
1.创建数据库表创建MySQL数据表需要以下信息:表名表字段名定义每个表字段语法:CREATE TABLE table_name (column_name column_type); 实例:CREATE TABLE IF NOT EXISTS `t_userinfo`( `userid` INT U ...
分类:
数据库 时间:
2019-09-21 01:30:12
阅读次数:
186
题目描述 Alice和Bob现在要乘飞机旅行,他们选择了一家相对便宜的航空公司。该航空公司一共在nnn个城市设有业务,设这些城市分别标记为000到n?1n-1n?1,一共有mmm种航线,每种航线连接两个城市,并且航线有一定的价格。 Alice和Bob现在要从一个城市沿着航线到达另一个城市,途中可以进 ...
分类:
其他好文 时间:
2019-09-18 00:33:10
阅读次数:
131
1、List内部功能 (1)extend:扩展 Eg: Li=[1,2,3] Li.extend([22,33]) Print(li) (2)insert:在指定位置插入值 eg: Li.insert(0,’alice’) (3)pop():可以指定弹出一个数,也可以默认弹出最上面的数字,可以获取返 ...
分类:
编程语言 时间:
2019-09-16 22:06:07
阅读次数:
171
In this challenge, you will create the username portion of a registration system. All usernames must be unique. If a new user requests a name that is ...
分类:
其他好文 时间:
2019-09-12 18:36:50
阅读次数:
123
原题链接在这里:https://leetcode.com/problems/new-21-game/ 题目: Alice plays the following game, loosely based on the card game "21". Alice starts with 0 points ...
分类:
其他好文 时间:
2019-09-09 12:56:07
阅读次数:
86
Cake Robbery Time Limit: 2000 msMemory Limit: 65536 KB As usual, Alice finishes her delicious cake at noon. Unfortunately, the smell of cake beckoned ...
分类:
其他好文 时间:
2019-09-08 20:28:36
阅读次数:
75
一、编码规范(参考来源:https://blog.csdn.net/aaaaa_alice/article/details/82144460, https://segmentfault.com/a/1190000019852405) 1、开始 命名: 类名首字母应该大写 字段、方法以及对象(句柄)的 ...
分类:
其他好文 时间:
2019-09-08 09:59:23
阅读次数:
95
在上一章中, 我们已经将 n维数组与指针的联系 讲完了, 现在要介绍的是非常高级的 C++ 指针, 指针的内容必须完全掌握才可进入此篇, 没有掌握看此篇 请注意: 部分 IDE (如 Dev-Cpp) 不支持 C++11 或没有 <memory> 头文件者, 请跳过此篇 在 C++ 官网 中已经详细 ...
分类:
编程语言 时间:
2019-08-31 12:57:33
阅读次数:
98