上一页 1 ··· 162 163 164 165 166 167 168 169 170 ··· 273 下一页
摘要: Given n points in the plane that are all pairwise distinct, a "boomerang" is a tuple of points (i, j, k) such that the distance between i and j equals 阅读全文
posted @ 2018-04-01 22:16 bonelee 阅读(278) 评论(0) 推荐(0)
摘要: Given a non-empty array of non-negative integers nums, the degree of this array is defined as the maximum frequency of any one of its elements. Your t 阅读全文
posted @ 2018-04-01 21:07 bonelee 阅读(220) 评论(0) 推荐(0)
摘要: Reverse a singly linked list. click to show more hints. 精简下代码: 递归解: dfs 记得程序员面试金典里专门提过! 阅读全文
posted @ 2018-04-01 16:46 bonelee 阅读(155) 评论(0) 推荐(0)
摘要: Given scores of N athletes, find their relative ranks and the people with the top three highest scores, who will be awarded medals: "Gold Medal", "Sil 阅读全文
posted @ 2018-04-01 12:29 bonelee 阅读(179) 评论(0) 推荐(0)
摘要: Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the arr 阅读全文
posted @ 2018-04-01 10:36 bonelee 阅读(139) 评论(0) 推荐(0)
摘要: Given a string, find the first non-repeating character in it and return it's index. If it doesn't exist, return -1. Examples: s = "leetcode" return 0. 阅读全文
posted @ 2018-03-30 22:32 bonelee 阅读(246) 评论(0) 推荐(0)
摘要: 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 - 阅读全文
posted @ 2018-03-30 22:08 bonelee 阅读(190) 评论(0) 推荐(0)
摘要: Assume you are an awesome parent and want to give your children some cookies. But, you should give each child at most one cookie. Each child i has a g 阅读全文
posted @ 2018-03-30 22:05 bonelee 阅读(187) 评论(0) 推荐(0)
摘要: 例如: python dig_ip.py 8264.comRecursive name lookup (simulates dig)...8264.com cname is qaz2d84guo7uz5q2.gfnormal01at.com.[u'121.29.18.91'] =>IP地址 pyth 阅读全文
posted @ 2018-03-30 11:05 bonelee 阅读(1662) 评论(0) 推荐(0)
摘要: Given a Binary Search Tree (BST) with the root node root, return the minimum difference between the values of any two different nodes in the tree. Exa 阅读全文
posted @ 2018-03-29 23:12 bonelee 阅读(475) 评论(0) 推荐(0)
上一页 1 ··· 162 163 164 165 166 167 168 169 170 ··· 273 下一页