上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 29 下一页
摘要: Given a non-negative integer represented as a non-empty array of digits, plus one to the integer. You may assume the integer do not contain any leadin 阅读全文
posted @ 2017-12-03 12:45 jasminemzy 阅读(142) 评论(0) 推荐(0) 编辑
摘要: A 2d grid map of m rows and n columns is initially filled with water. We may perform an addLand operation which turns the water at position (row, col) 阅读全文
posted @ 2017-12-03 11:22 jasminemzy 阅读(93) 评论(0) 推荐(0) 编辑
摘要: Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations: get and put. get(key) - Get the 阅读全文
posted @ 2017-12-03 09:18 jasminemzy 阅读(139) 评论(0) 推荐(0) 编辑
摘要: Given an Iterator class interface with methods: next() and hasNext(), design and implement a PeekingIterator that support the peek() operation -- it e 阅读全文
posted @ 2017-12-03 07:16 jasminemzy 阅读(157) 评论(0) 推荐(0) 编辑
摘要: Given two sentences words1, words2 (each represented as an array of strings), and a list of similar word pairs pairs, determine if two sentences are s 阅读全文
posted @ 2017-12-03 06:05 jasminemzy 阅读(334) 评论(0) 推荐(0) 编辑
摘要: Equations are given in the format A / B = k, where A and B are variables represented as strings, and k is a real number (floating point number). Given 阅读全文
posted @ 2017-12-03 05:02 jasminemzy 阅读(145) 评论(0) 推荐(0) 编辑
摘要: Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid. The brackets must close in the 阅读全文
posted @ 2017-12-02 03:11 jasminemzy 阅读(200) 评论(0) 推荐(0) 编辑
摘要: Given a string s, find the longest palindromic substring in s. You may assume that the maximum length of s is 1000. Example: Example: 1. O(n3)复杂度做。双层f 阅读全文
posted @ 2017-12-02 02:55 jasminemzy 阅读(146) 评论(0) 推荐(0) 编辑
摘要: Validate if a given string is numeric. Some examples:"0" => true" 0.1 " => true"abc" => false"1 a" => false"2e10" => true Note: It is intended for the 阅读全文
posted @ 2017-12-01 14:21 jasminemzy 阅读(203) 评论(0) 推荐(0) 编辑
摘要: Design a data structure that supports all following operations in average O(1) time. Note: Duplicate elements are allowed. Example: 算法:试了一下用双Map无法实现频率 阅读全文
posted @ 2017-12-01 13:08 jasminemzy 阅读(142) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 29 下一页