feng鸽的博客

山不在高,有仙则名.

LeetCode第797题 All Paths From Source to Target

class Solution {public:    vector<vector<int>> paths;        void findPath(vector<vector&a...

2018-04-07 21:25:56

阅读数:15

评论数:0

LeetCode 789

class Solution {public:    bool escapeGhosts(vector<vector<int>>& ghosts, vector<i...

2018-04-06 22:30:35

阅读数:11

评论数:0

LeetCode787题

There are n cities connected by m flights. Each fight starts from city u and arrives at v with a price w.Now given all the cities and fights, togethe...

2018-04-06 14:06:15

阅读数:14

评论数:0

LeetCode第676题

Implement a magic directory with buildDict, and search methods.For the method buildDict, you'll be given a list of non-repetitive words to build a di...

2018-04-05 21:37:49

阅读数:3

评论数:0

LeetCode 695. Max Area of Island

Given a non-empty 2D array grid of 0's and 1's, an island is a group of 1's (representing land) connected 4-directionally (horizontal or vertical.) Y...

2018-04-02 00:54:11

阅读数:11

评论数:0

LeetCode第628题

Given an integer array, find three numbers whose product is maximum and output the maximum product.Example 1:Input: [1,2,3] Output: 6 Example 2:Input...

2018-04-01 17:11:05

阅读数:10

评论数:0

leetcode605题(2 Keys Keyboard)

class Solution { public: int minSteps(int n) { if (n <= 1) { // 如果需要的长度小于等于1,那就不需要操作了,直接返回0 return 0; } ...

2018-03-26 22:30:37

阅读数:16

评论数:0

LeetCode605题 (2 Keys Keyboard)

int MAX = 1001; class Solution { public: int dp(int n, int have, int c) { //have代表已经有了几个A,c代表当前复制板上有几个A if (n == have) { // 如果已经到达目标,返回0...

2018-03-26 22:14:14

阅读数:13

评论数:0

leetcode第十题

Implement regular expression matching with support for '.' and '*'. '.' Matches any single character. '*' Matches zero or more of the preceding elem...

2018-02-05 00:11:41

阅读数:38

评论数:0

leetcode第一题(TWO SUM)

Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input would have ...

2018-02-03 23:29:42

阅读数:23

评论数:0

提示
确定要删除当前文章?
取消 删除
关闭
关闭