
LeetCode
half1_2_1
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
LeetCode263:Ugly Number
Write a program to check whether a given number is an ugly number. Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. For example, 6, 8 are ugly while 14 is not ugly since it原创 2015-08-21 15:53:22 · 489 阅读 · 0 评论 -
LeetCode258:Add Digits
Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. For example: Given num = 38, the process is like: 3 + 8 = 11, 1 + 1 = 2. Since 2 has only one原创 2015-08-21 16:20:36 · 612 阅读 · 0 评论 -
LeetCode203:Remove Linked List Elements
Remove all elements from a linked list of integers that have value val. Example Given: 1 --> 2 --> 6 --> 3 --> 4 --> 5 --> 6, val = 6 Return: 1 --> 2 --> 3 --> 4 --> 5 解法思路:在链表头添加一个结点,对链表进原创 2015-11-17 17:56:28 · 352 阅读 · 0 评论 -
LeetCode237:Delete Node in a Linked List
Write a function to delete a node (except the tail) in a singly linked list, given only access to that node. Supposed the linked list is 1 -> 2 -> 3 -> 4 and you are given the third node with value原创 2015-11-17 17:15:57 · 328 阅读 · 0 评论