摘要: 题目: Write a program to solve a Sudoku puzzle by filling the empty cells. Empty cells are indicated by the character '.'. You may assume that there wil 阅读全文
posted @ 2016-08-25 23:10 wangxiaobao1114 阅读(177) 评论(0) 推荐(0) 编辑
摘要: The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ... 1 is read off as "one 1" or 11.11 is read off 阅读全文
posted @ 2016-08-24 21:28 wangxiaobao1114 阅读(116) 评论(0) 推荐(0) 编辑
摘要: 题目: Determine if a Sudoku is valid, according to: Sudoku Puzzles - The Rules. The Sudoku board could be partially filled, where empty cells are filled 阅读全文
posted @ 2016-08-24 21:26 wangxiaobao1114 阅读(125) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a sorted array and a target value, return the index if the target is found. If not, return the index where it would be if it were inserted i 阅读全文
posted @ 2016-08-23 20:47 wangxiaobao1114 阅读(157) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a sorted array of integers, find the starting and ending position of a given target value. Your algorithm's runtime complexity must be in th 阅读全文
posted @ 2016-08-23 20:43 wangxiaobao1114 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a string containing just the characters '(' and ')', find the length of the longest valid (well-formed) parentheses substring. For "(()", th 阅读全文
posted @ 2016-08-22 21:07 wangxiaobao1114 阅读(325) 评论(0) 推荐(0) 编辑
摘要: 题目: Suppose a sorted array is rotated at some pivot unknown to you beforehand. (i.e., 0 1 2 4 5 6 7 might become 4 5 6 7 0 1 2). You are given a targe 阅读全文
posted @ 2016-08-20 22:13 wangxiaobao1114 阅读(223) 评论(0) 推荐(0) 编辑
摘要: 题目: Implement next permutation, which rearranges numbers into the lexicographically next greater permutation of numbers. If such arrangement is not po 阅读全文
posted @ 2016-08-19 22:47 wangxiaobao1114 阅读(183) 评论(0) 推荐(0) 编辑
摘要: 题目: You are given a string, s, and a list of words, words, that are all of the same length. Find all starting indices of substring(s) in s that is a c 阅读全文
posted @ 2016-08-18 22:16 wangxiaobao1114 阅读(254) 评论(0) 推荐(0) 编辑
摘要: 题目: Divide two integers without using multiplication, division and mod operator. If it is overflow, return MAX_INT. (Medium) 分析: 题目要求不使用乘除和模运算实现两个整数除法 阅读全文
posted @ 2016-08-17 22:18 wangxiaobao1114 阅读(146) 评论(0) 推荐(0) 编辑