摘要:
"116. Jump Game" / "55. Jump Game" 本题难度: Medium Topic: Greedy Description Given an array of non negative integers, you are initially positioned at the 阅读全文
摘要:
"182. Delete Digits" 本题难度: Medium Topic: Greedy Description Given string A representative a positive integer which has N digits, remove any k digits o 阅读全文
摘要:
"184. Largest Number" / "179. Largest Number" 本题难度: Medium Topic: Greedy Description 184. Largest Number 中文English Given a list of non negative intege 阅读全文
摘要:
"187. Gas Station" / "134. Gas Station" 本题难度: Medium Topic: Greedy Description There are N gas stations along a circular route, where the amount of ga 阅读全文
摘要:
"46. Majority Element" /[169. Majority Element(https://leetcode.com/problems/majority element/) 本题难度: Easy Topic: Greedy Description Given an array of 阅读全文
摘要:
"82. Single Number" / "136. Single Number" 本题难度: Easy Topic: Greedy Description Given a non empty array of integers, every element appears twice excep 阅读全文
摘要:
"163. Unique Binary Search Trees" 本题难度: Medium Topic: Bit Manipulation Description Given n, how many structurally unique BSTs (binary search trees) th 阅读全文
摘要:
"179. Update Bits" 本题难度: Medium Topic: Bit Manipulation Description Given two 32 bit numbers, N and M, and two bit positions, i and j. Write a method 阅读全文
摘要:
"140. Fast Power" 本题难度: Medium Topic: Bit Manipulation Description Calculate the a^n % b where a, b and n are all 32bit positive integers. Example For 阅读全文
摘要:
"180. Binary Representation" 本题难度: Hard Topic: Bit Manipulation Description Given a (decimal e.g. 3.72) number that is passed in as a string, return t 阅读全文
摘要:
"191. Number of 1 Bits" 本题难度: Easy Topic: Bit Manipulation Description Write a function that takes an unsigned integer and return the number of '1' bi 阅读全文
摘要:
"2. Trailing Zeros" 本题难度: Easy Topic: Math&Bit Manipulation Description Write an algorithm which computes the number of trailing zeros in n factorial. 阅读全文
摘要:
"142. O(1) Check Power of 2" 本题难度: Easy Topic: Math&Bit Manipulation Description Using O(1) time to check whether an integer n is a power of 2. Exampl 阅读全文
摘要:
"181. Flip Bits" 本题难度: Easy Topic: Math&Bit Manipulation Description Determine the number of bits required to flip if you want to convert integer n to 阅读全文
摘要:
"183. Wood Cut" 本题难度: Hard Topic: Binary Search Description Given n pieces of wood with length L[i] (integer array). Cut them into small pieces to gua 阅读全文
摘要:
"[Lintcode]61. Search for a Range" / "[Leetcode]34. Find First and Last Position of Element in Sorted Array" 本题难度: Medium/Medium Topic: Binary Search 阅读全文
摘要:
"81. Search in Rotated Sorted Array II" 本题难度: Medium Topic: Binary Search 类似 "[Lintcode]62. Search in Rotated Sorted Array/[Leetcode]33. Search in Rot 阅读全文
摘要:
"[Lintcode]62. Search in Rotated Sorted Array" / "[Leetcode]33. Search in Rotated Sorted Array" 本题难度: Medium/Medium Topic: Binary Search Description 6 阅读全文