Given a linked list, swap every two adjacent nodes and return its head. You may not modify the values in the list's nodes, only nodes itself may be ch ...
分类:
其他好文 时间:
2019-12-29 12:53:05
阅读次数:
85
题目如下: Given a binary tree, return the sum of values of its deepest leaves. Example 1: Constraints: The number of nodes in the tree is between 1 and 10 ...
分类:
其他好文 时间:
2019-12-29 10:38:07
阅读次数:
72
```javascript function Node() { this.endCount = 0 this.word = '' this.children = {} } class Tire { constructor() { this.root = new Node() } addWord... ...
分类:
其他好文 时间:
2019-12-28 22:44:48
阅读次数:
65
Py西游攻关之基础数据类型 - Yuan先生 https://www.cnblogs.com/yuanchenqi/articles/5782764.html 七 Dictionary(字典) 字典是python中唯一的映射类型,采用键值对(key-value)的形式存储数据。python对key进 ...
分类:
其他好文 时间:
2019-12-28 19:13:33
阅读次数:
112
numStr = input("请输入一个大于1的正整数:") n = int(numStr) m = n * n i = 1 numbers = [] values = [] while i <=n: #生成列表 values.apped(i) if i % n ==0: numbers.appe ...
分类:
编程语言 时间:
2019-12-27 23:33:04
阅读次数:
452
1. [{} ] all_users = models.User.objects.all().values('name','age','role__name') 2. [ 对象 ] all_users = models.User.objects.all() 用的时候注意,只拿自己表中的字段,别跨表 ...
分类:
其他好文 时间:
2019-12-27 15:16:11
阅读次数:
63
两个函数细节记不住. 写个例子备注一下. 结果 | no | name | score | rk1 | rk2 | rn1 | rn2 | | | | | | | | | | 1 | b | 2 | 5 | 1 | 5 | 1 | | 1 | a | 1 | 3 | 2 | 3 | 2 | | 1 ...
分类:
数据库 时间:
2019-12-27 11:52:38
阅读次数:
93
在sqlserver里,可以利用系统表master..spt_values里面存储的连续数字0到2047,结合dateadd()函数生成连续的日期。 SELECT CONVERT (VARCHAR (10),dateadd(d, number, '2019-05-30'),23) AS rq FRO ...
分类:
数据库 时间:
2019-12-27 11:29:40
阅读次数:
189
Array.prototype.values = function(){ let i = 0; let self = this return { next(){ const done = i>= self.length const value = done? undefined : self[i++ ...
分类:
其他好文 时间:
2019-12-27 00:17:40
阅读次数:
72
golang 调用顺丰API接口首先得去https://qiao.sf-express.com/pages/service/API.html这个网站申请注册,拿到我的API接口如下图所示 之后就可以按照文档生成xml请求信息 为了方便快速搭建 golang 的结构粘贴如下 将数据结构转换为xml格式 ...