题目: 反转链表 II:反转从位置 m 到 n 的链表。请使用一趟扫描完成反转。 反转从位置 m 到 n 的链表。请使用一趟扫描完成反转。 说明:1 ≤ m ≤ n ≤ 链表长度。 示例:输入: 1->2->3->4->5->NULL, m = 2, n = 4输出: 1->4->3->2->5-> ...
分类:
编程语言 时间:
2020-05-02 22:56:54
阅读次数:
130
In a sequence of numbers,we can find some number pairs that conform to the rule below: Assuming that there exist two numbers,N and M and it's position ...
分类:
其他好文 时间:
2020-05-02 18:46:09
阅读次数:
60
The lowest common ancestor (LCA) of two nodes U and V in a tree is the deepest node that has both U and V as descendants. A binary search tree (BST) i ...
分类:
其他好文 时间:
2020-05-02 14:54:12
阅读次数:
50
加密代码 unctf{b66_6b6_66b} ...
分类:
其他好文 时间:
2020-05-01 16:25:47
阅读次数:
55
反转链表二。也是不会做,会写homebrew也枉然的题目,但是非常容易错。题意是给一个链表和两个数字m和n,请反转m和n之间的node,只能走一次。例子, Example: Input: 1->2->3->4->5->NULL, m = 2, n = 4 Output: 1->4->3->2->5- ...
分类:
其他好文 时间:
2020-05-01 10:28:20
阅读次数:
47
给定一个链表,两两交换其中相邻的节点,并返回交换后的链表。 你不能只是单纯的改变节点内部的值,而是需要实际的进行节点交换。 示例: 给定 1->2->3->4, 你应该返回 2->1->4->3. 来源:力扣(LeetCode) 类似于链表反转,三个指针记录位置。 /** * Definition ...
分类:
其他好文 时间:
2020-05-01 00:42:44
阅读次数:
79
```java package 链表; /** * https://leetcode-cn.com/problems/reverse-linked-list/ * 206. 反转链表 * * 解题思路 :使用给定节点的后一个节点的值覆盖给定节点的值,然后删除下一个节点 */ public class... ...
分类:
其他好文 时间:
2020-04-30 19:39:32
阅读次数:
56
The User Event module is part of the Testing Library family of tools and lets you fire events on DOM nodes that more closely resemble the way your use ...
分类:
其他好文 时间:
2020-04-30 19:32:54
阅读次数:
70
1.不使用flex时,在index.wxml里写格式 2.在index.wxss里写样式 3.开始启用flex格式 3.1 flex-flow: row; 元素按照一行排列; flex-flow: column; 元素按照一列排列 3.2 flex-direction: column; 元素排列方式 ...
分类:
微信 时间:
2020-04-29 16:29:31
阅读次数:
275
1. deque 的数据存取 这个部分和 vector 几乎一样 第一 使用下标操作 dequeName[0] = 100; //小心越界 第二 使用at 方法 如: dequeName.at(2) = 100; //小心越界 第三 接口返回的引用 dequeName.front() 和 deqIn ...
分类:
其他好文 时间:
2020-04-29 09:16:31
阅读次数:
93