自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(9)
  • 收藏
  • 关注

原创 动态规划 硬币兑换

参考// 最少硬币.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include <iostream>#include <vector>#include <map>#include <limits>using namespace std;class hh {public: vector&l...

2018-05-20 22:07:15 569

原创 Leetcode 47. Permutations II

class Solution {public: bool repeat(vector<int>& nums, int begin,int j) { for (int i = begin; i < j; i++) { if (nums[i] == nums[j]) { return true; } } return fa...

2018-05-16 17:22:15 98

原创 Leetcode 46. Permutations 全排列 标准回溯法

class Solution {public: void fun(vector<vector<int>> &ans, vector<int>& nums, vector<int> &temp,int index) { if (index == nums.size()-1) { temp.push_back...

2018-05-16 17:06:32 432

原创 Leetcode 113. Path Sum II

/** * Definition for a binary tree node. * public class TreeNode { * int val; * TreeNode left; * TreeNode right; * TreeNode(int x) { val = x; } * } */class Solution { pri...

2018-05-08 14:45:52 164

原创 Leetcode 112. Path Sum

112. Path SumDescriptionHintsSubmissionsDiscussSolutionPick OneGiven a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the...

2018-05-08 11:03:48 118

转载 关于 Can't connect to MySQL server on 'localhost' (10061) 的一个解决方案

https://www.cnblogs.com/yueyingshuanglan/p/6689974.html问题描述:使用Navicat for mysql 无法远程连接到本地数据库,提示Can't connect to MySQL server on 'localhost' (10038) .本地服务中MySql 服务没有启动,也找不到该服务。使用CMD 命令行打开MySql 提示 Can't...

2018-05-07 17:18:34 672

原创 LeetCode 110. Balanced Binary Tree

/** * Definition for a binary tree node. * public class TreeNode { * int val; * TreeNode left; * TreeNode right; * TreeNode(int x) { val = x; } * } */class Solution{ publ...

2018-05-04 15:19:23 125

原创 Leetcode 109. Convert Sorted List to Binary Search Tree

/** * Definition for singly-linked list. * public class ListNode { * int val; * ListNode next; * ListNode(int x) { val = x; } * } *//** * Definition for a binary tree node. * pub...

2018-05-04 14:06:35 129

原创 Leetcode 22. Generate Parentheses

class Solution {public: /* 左括号不超过n个 有左才有右 右括号个数不超过左括号 开头左括号 结尾右括号 */ vector<string> ans; void fun(int n,int m,string &s,int left,int right) //n为回溯法里面的层数 { if (n == (m-1)) { ...

2018-05-04 12:47:21 138

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

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