<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[Neo_dot的博客]]></title><description><![CDATA[]]></description><link>https://blog.youkuaiyun.com/Neo_dot</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; Neo_dot]]></copyright><item><title><![CDATA[【算法刷题】leetcode   subsets ii]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/82221781</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/82221781</guid><author>Neo_dot</author><pubDate>Thu, 30 Aug 2018 15:10:22 +0800</pubDate><description><![CDATA[Given a collection of integers that might contain duplicates, S, return all possible subsets.

Note:

Elements in a subset must be in non-descending order.
	The solution set must not contain duplicate...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode  restore-ip-addresses]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/82221711</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/82221711</guid><author>Neo_dot</author><pubDate>Thu, 30 Aug 2018 15:07:59 +0800</pubDate><description><![CDATA[Given a string containing only digits, restore it by returning all possible valid IP address combinations.

For example:
Given&quot;25525511135&quot;,

return[&quot;255.255.11.135&quot;, &quot;255.255.111.35&quot;]. (Order does no...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode    Distinct Subsequences]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81667784</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81667784</guid><author>Neo_dot</author><pubDate>Tue, 14 Aug 2018 15:39:58 +0800</pubDate><description><![CDATA[Given a string S and a string T, count the number of distinct subsequences of T in S.

A subsequence of a string is a new string which is formed from the original string by deleting some (can be none)...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode   Maximal-Rectangle]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81627667</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81627667</guid><author>Neo_dot</author><pubDate>Mon, 13 Aug 2018 12:16:41 +0800</pubDate><description><![CDATA[Given a 2D binary matrix filled with 0's and 1's, find the largest rectangle containing all ones and return its area.

 

思路参考  blog

 


    int maximalRectangle(vector&amp;lt;vector&amp;lt;char&amp;gt; &amp;gt; &amp;am...]]></description><category></category></item><item><title><![CDATA[【算法刷题】 leetcode   Largest Rectangle in Histogram]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81178661</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81178661</guid><author>Neo_dot</author><pubDate>Tue, 24 Jul 2018 09:32:41 +0800</pubDate><description><![CDATA[Given n non-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in the histogram.



Above is a histogram where width of each...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode     longest-consecutive- sequence]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81156739</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81156739</guid><author>Neo_dot</author><pubDate>Sun, 22 Jul 2018 17:47:28 +0800</pubDate><description><![CDATA[Given an unsorted array of integers, find the length of the longest consecutive elements sequence.

For example,
Given[100, 4, 200, 1, 3, 2],
The longest consecutive elements sequence is[1, 2, 3, 4]. ...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode  surrounded region]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81156303</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81156303</guid><author>Neo_dot</author><pubDate>Sun, 22 Jul 2018 17:07:25 +0800</pubDate><description><![CDATA[Given a 2D board containing'X'and'O', capture all regions surrounded by'X'.

A region is captured by flipping all'O's into'X's in that surrounded region .

For example,


X X X X
X O O X
X X O X
X O X...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode    分割回文串]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81053895</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81053895</guid><author>Neo_dot</author><pubDate>Sun, 15 Jul 2018 16:09:04 +0800</pubDate><description><![CDATA[Given a string s, partition s such that every substring of the partition is a palindrome.Return all possible palindrome partitioning of s.For example, given s =&quot;aab&quot;,Return  [
    [&quot;aa&quot;,&quot;b&quot;],
    [&quot;a&quot;...]]></description><category></category></item><item><title><![CDATA[【算法刷题】   单链表的快排和归并排序]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81046141</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81046141</guid><author>Neo_dot</author><pubDate>Sat, 14 Jul 2018 18:18:50 +0800</pubDate><description><![CDATA[快排： struct ListNode {
      int val;
      ListNode *next;
      ListNode(int x) : val(x), next(NULL) {}
  };



	
	 void swap(ListNode *l, ListNode *r)
	 {
		 int temp = l-&amp;gt;val;
		 l-&amp;gt;val = r-&amp;...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode    gas-station]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/81007699</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/81007699</guid><author>Neo_dot</author><pubDate>Wed, 11 Jul 2018 22:06:55 +0800</pubDate><description><![CDATA[There are N gas stations along a circular route, where the amount of gas at station iisgas[i].You have a car with an unlimited gas tank and it costscost[i]of gas to travel from station i to its next s...]]></description><category></category></item><item><title><![CDATA[【算法刷题】N皇后问题]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80996220</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80996220</guid><author>Neo_dot</author><pubDate>Wed, 11 Jul 2018 10:21:45 +0800</pubDate><description><![CDATA[主要思想就是递归回溯，一行一行的加，每次确保前边的都满足要求，因此，新加入的一行只需与遍历前边已加入的行，是否满足要求即可//N-Queens
//一行一行放置使其不冲突  递归回溯

	//检查最后一行的皇后，和前边行的是否冲突
	bool check(int row, vector&amp;lt;int&amp;gt; Queen)
	{
		for (int i = 0; i &amp;lt; row; ++i)
...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode  word ladder]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80954237</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80954237</guid><author>Neo_dot</author><pubDate>Sat, 07 Jul 2018 19:58:54 +0800</pubDate><description><![CDATA[Given two words (start and end), and a dictionary, find the length of shortest transformation sequence from start to end, such that:Only one letter can be changed at a timeEach intermediate word must ...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode     jump game]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80951112</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80951112</guid><author>Neo_dot</author><pubDate>Sat, 07 Jul 2018 15:31:06 +0800</pubDate><description><![CDATA[基础版：是否能到达Given an array of non-negative integers, you are initially positioned at the first index of the array.Each element in the array represents your maximum jump length at that position.Determine ...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode Reverse digits of an integer.]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80918458</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80918458</guid><author>Neo_dot</author><pubDate>Wed, 04 Jul 2018 20:55:11 +0800</pubDate><description><![CDATA[Example1: x = 123, return 321Example2: x = -123, return -321click to show spoilers.Have you thought about this?Here are some good questions to ask before coding. Bonus points for you if you have alrea...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode  reorder-list]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80917419</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80917419</guid><author>Neo_dot</author><pubDate>Wed, 04 Jul 2018 19:26:43 +0800</pubDate><description><![CDATA[Given a singly linked list L: L 0→L 1→…→L n-1→L n,reorder it to: L 0→L n →L 1→L n-1→L 2→L n-2→…You must do this in-place without altering the nodes' values.For example,Given{1,2,3,4}, reorder it to{1,...]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode   word-break]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80913860</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80913860</guid><author>Neo_dot</author><pubDate>Wed, 04 Jul 2018 16:06:56 +0800</pubDate><description><![CDATA[Given a string s and a dictionary of words dict, determine if s can be segmented into a space-separated sequence of one or more dictionary words.For example, givens =&quot;leetcode&quot;,dict =[&quot;leet&quot;, &quot;code&quot;]....]]></description><category></category></item><item><title><![CDATA[【算法刷题】leetcode   Candy]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80877183</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80877183</guid><author>Neo_dot</author><pubDate>Sun, 01 Jul 2018 20:33:52 +0800</pubDate><description><![CDATA[There are N children standing in a line. Each child is assigned a rating value.You are giving candies to these children subjected to the following requirements:Each child must have at least one candy....]]></description><category></category></item><item><title><![CDATA[【算法刷题】8皇后问题]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80751954</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80751954</guid><author>Neo_dot</author><pubDate>Wed, 20 Jun 2018 20:03:49 +0800</pubDate><description><![CDATA[利用一个8个元素数组:queen[i]表示第i行的皇后所在列数；8个元素只能从0-7中选择，每个只能一次，这就保证了皇后不处在同一列或同一行，对于不处对角：任意两行的皇后i、j，不在对角满足|i-j|！=|queen[i]-queen[j]|由此，可解题：queen数组的全排列，对于全排列中每一个可能性，判断不在对角的条件//8皇后问题
//全排列+逐个判断
int g_number = 0;
v...]]></description><category></category></item><item><title><![CDATA[【算法刷题】字符串的组合（非排列）]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80731767</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80731767</guid><author>Neo_dot</author><pubDate>Tue, 19 Jun 2018 11:39:13 +0800</pubDate><description><![CDATA[递归的思想：n个字符里取出m个从头扫描字符串的第一个字符。针对第一个字符，有两种选择：要么取第一个，剩下n-1个取m-1个，要么第一不取，剩下n-1个中取m个，递归实现//n个字符里取出m个，递归实现
//要么取第一个，剩下n-1个取m-1个，要么第一不取，剩下n-1个中取m个
void Combination(char* str, int length, vector&amp;lt;char&amp;gt;&amp;a...]]></description><category></category></item><item><title><![CDATA[【C++总结记载】类对象、继承、虚继承、虚函数表]]></title><link>https://blog.youkuaiyun.com/Neo_dot/article/details/80725800</link><guid>https://blog.youkuaiyun.com/Neo_dot/article/details/80725800</guid><author>Neo_dot</author><pubDate>Mon, 18 Jun 2018 20:01:25 +0800</pubDate><description><![CDATA[关于虚函数表，可见博客    传送    ，但是要注意，一般被继承的第一个基类的虚函数表合并至子类的虚函数表，（基类的虚函数在前，除非有虚函数覆盖，子类的虚函数在后）

主要讲了在无虚继承情况下各种情况的虚函数表的情况，

因此，就牵扯到了类的大小的问题：

1）对于一个空类，sizeof=1；

2）静态成员不属于类大小中，且成员函数也不属于类大小中

3）类与继承情况下类的大小：

情况一： ...]]></description><category></category></item></channel></rss>