
leetcode
文章平均质量分 56
舒米乐的帽子
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
leetcode 刷题
题目一:leetcode200Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacent lands horizontally or vertically....原创 2018-07-10 15:36:58 · 528 阅读 · 0 评论 -
LEETCODE 283. Move Zeroes 三种解体方案
Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. Example: Input: [0,1,0,3,12] Output: [1,3,12,0,0] Note: You must do this in-place without making a copy of the arr原创 2018-08-13 15:18:22 · 155 阅读 · 0 评论 -
合并两个有序链表,合并之后任然是有序的并输出。
合并链表相信大家都特别熟悉,但是如果要加上一定的输出格式,难度就会有所增加,不说了,见代码。 #include<iostream> using namespace std; struct Node{ Node *next; int data; }; void nodeprint(Node *head){ Node *node=head; while...原创 2018-10-12 15:21:07 · 251 阅读 · 0 评论