摘要:
1.Contains Duplicate 题目链接 题目要求: Given an array of integers, find if the array contains any duplicates. Your function should return true if any val... 阅读全文
摘要:
题目链接 题目要求: Given an array of integers, every element appearstwiceexcept for one. Find that single one. Note: Your algorithm should have a linear... 阅读全文
摘要:
题目链接 题目要求: Determine if a Sudoku is valid, according to:Sudoku Puzzles - The Rules. The Sudoku board could be partially filled, where empty cells... 阅读全文
摘要:
1. Two Sum 题目链接 题目要求: Given an array of integers, find two numbers such that they add up to a specific target number. The function twoSum shoul... 阅读全文
摘要:
题目链接 题目要求: Given a non-negative number represented as an array of digits, plus one to the number. The digits are stored such that the most signif... 阅读全文
摘要:
题目链接 题目要求: The demons had captured the princess (P) and imprisoned her in the bottom-right corner of a dungeon. The dungeon consists of M x N room... 阅读全文
摘要:
题目链接 题目要求: Given a list of non negative integers, arrange them such that they form the largest number. For example, given[3, 30, 34, 5, 9], the l... 阅读全文
摘要:
题目链接 题目要求: The string"PAYPALISHIRING"is written in a zigzag pattern on a given number of rows like this: (you may want to display this pattern in ... 阅读全文
摘要:
题目链接 题目要求: Rotate an array ofnelements to the right byksteps. For example, withn= 7 andk= 3, the array[1,2,3,4,5,6,7]is rotated to[5,6,7,1,2,3,4]... 阅读全文