![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
leetcode
SYSUSDCSGJH
这个作者很懒,什么都没留下…
展开
-
[leetcode] 25. Reverse Nodes in k-Group
题意 如例子所示,给定一个链表,以k个元素作为一组,将它们倒置,若剩余不足k个,保持不变。 Given this linked list: 1->2->3->4->5 For k = 2, you should return: 2->1->4->3->5 For k = 3, you should return: 3->2->1->...原创 2019-04-13 20:24:08 · 117 阅读 · 0 评论 -
[leetcode] 30. Substring with Concatenation of All Words
题意 给定字符串s和单词集合words,words里面的所有word以任意顺序组合成一个新的字符串t,其中要求每个word出现且仅出现1次,问在组合字符串t是否是s的字串,若是,求出t在s开始的下标,题目要求求出所有满足要求的下标。 题解 window slide 代码 static int x=[](){ std::ios::sync_with_stdio(false); cin...原创 2019-08-25 16:48:45 · 101 阅读 · 0 评论