<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[yao_hust_iAC的专栏]]></title><description><![CDATA[]]></description><link>https://blog.youkuaiyun.com/yao_wust</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; yao_wust]]></copyright><item><title><![CDATA[《Linux内核设计与实现》读书笔记之进程地址空间]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46413293</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46413293</guid><author>yao_wust</author><pubDate>Mon, 08 Jun 2015 18:04:42 +0800</pubDate><description><![CDATA[1.进程的内核区域包含各种内存对象      
      进程的内核区域包含各种内存对象，比如：
1.可执行文件代码可以包含各种内存映射，称为代码段（text section）。
2.可执行文件的已初始化全局变量的内存映射，称为数据段（data section）。
3.包含未初始化全局变量，也就是bss段的零页（页面中的信息全部为0值，所以可以用于映射bss段等目的）的内存映射。
4.]]></description><category></category></item><item><title><![CDATA[《Linux内核设计与实现》读书笔记之内存管理]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46356833</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46356833</guid><author>yao_wust</author><pubDate>Thu, 04 Jun 2015 11:34:45 +0800</pubDate><description><![CDATA[1.页
       内核把物理页作为内存管理的基本单位，MMU（内存管理单元）以页为单位来管理系统中的页表，从虚拟内存的角度来看，页就是最小单位。
       内核用struct page结构来标识系统中的每一个物理页，它的定义如下：


       flag域用来存放页的状态（是不是脏的，是不是被锁定在内存中等等）。_count表示这一页被引用了多少次，当次数为0时，表示此页没有]]></description><category></category></item><item><title><![CDATA[《Linux内核设计与实现》之中断与中断处理程序]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46300763</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46300763</guid><author>yao_wust</author><pubDate>Mon, 01 Jun 2015 10:53:02 +0800</pubDate><description><![CDATA[1.中断的概念
     中断本质上是一种特殊的电信号，由硬件设备发向处理器。处理器接收到中断后，会马上向操作系统反映此信号的到来，然后就由OS负责处理这些新到来的信号。
     从物理学的角度看，中断是一种电信号，有硬件设备产生，并直接送入中断控制器的输入引脚上。然后再由中断控制器向处理器发送相应的信号。处理器一经检测到此信号，便中断自己的当前工作转而处理中断。伺候处理器会通知操作系统已经]]></description><category></category></item><item><title><![CDATA[《Linux内核设计与实现》读书笔记之系统调用]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46271623</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46271623</guid><author>yao_wust</author><pubDate>Sat, 30 May 2015 10:55:31 +0800</pubDate><description><![CDATA[1.系统调用的概念
     为了和用户空间上运行的进程进行交互，内核提供了一组借口。透过该接口，应用程序可以访问硬件设备和其他操作系统资源。这组借口在应用程序和内核之间扮演着使者的角色。同时，这组接口也保证了系统稳定可靠，避免应用程序肆意妄行，惹出麻烦。Linux系统的系统调用作为C库的一部分提供，其调用过程中的实例如下图所示：


     从程序员的角度看，系统调用无关紧要，他们只需]]></description><category></category></item><item><title><![CDATA[《Linux内核设计与实现》读书笔记之进程管理]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46236423</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46236423</guid><author>yao_wust</author><pubDate>Fri, 29 May 2015 16:41:11 +0800</pubDate><description><![CDATA[1.进程描述符及任务结构
     Linux内核把进程存放在叫做任务队列的双向循环链表中。链表中的每一项都是类型为task_struct，称为进程描述符的结构。进程描述符包含一个具体进程的所有信息。
     task_struct相对较大，在32位的机器长，它大约有1.7K字节。进程描述符中的数据能完整的描述一个正在执行的程序：它打开的文件、进程的地址空间、挂起的信号、进程的状态，还有其他]]></description><category></category></item><item><title><![CDATA[Pascal's Triangle II]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46047419</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46047419</guid><author>yao_wust</author><pubDate>Wed, 27 May 2015 15:27:18 +0800</pubDate><description><![CDATA[题目描述：


Given an index k, return the kth row of the Pascal's triangle.

For example, given k = 3,
Return [1,3,3,1].


思路分析：依次计算每一行的值，把它们存在同一个数组里。


代码：
class Solution
{
	public:
		vector ]]></description><category></category></item><item><title><![CDATA[Pascal's Triangle]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/46004359</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/46004359</guid><author>yao_wust</author><pubDate>Tue, 26 May 2015 10:07:47 +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 ]]></description><category></category></item><item><title><![CDATA[LeetCode:Permutations]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45971249</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45971249</guid><author>yao_wust</author><pubDate>Mon, 25 May 2015 16:37:24 +0800</pubDate><description><![CDATA[题目描述：


Given a collection of numbers, return all possible permutations.

For example,
[1,2,3] have the following permutations:
[1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2],
 and [3,2,1].


]]></description><category></category></item><item><title><![CDATA[LeetCode:Spiral Matrix]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45848055</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45848055</guid><author>yao_wust</author><pubDate>Tue, 19 May 2015 18:21:14 +0800</pubDate><description><![CDATA[题目描述：


Given a matrix of m x n elements (m rows, n columns), return all elements of the matrix in spiral order.

For example,
Given the following matrix:
[
 [ 1, 2, 3 ],
 [ 4, 5, 6 ],
 [ 7, 8,]]></description><category></category></item><item><title><![CDATA[LeetCode:Interleaving String]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45846427</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45846427</guid><author>yao_wust</author><pubDate>Tue, 19 May 2015 16:38:49 +0800</pubDate><description><![CDATA[题目描述：


Given s1, s2, s3, find whether s3 is formed by the interleaving of s1 and s2.

For example,
Given:
s1 = "aabcc",
s2 = "dbbca",

When s3 = "aadbbcbcac", return true.
When s3 = "aadbb]]></description><category></category></item><item><title><![CDATA[LeetCode:Candy]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45845237</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45845237</guid><author>yao_wust</author><pubDate>Tue, 19 May 2015 15:30:44 +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 ]]></description><category></category></item><item><title><![CDATA[LeetCode:Word Search]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45824537</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45824537</guid><author>yao_wust</author><pubDate>Mon, 18 May 2015 17:01:00 +0800</pubDate><description><![CDATA[题目描述:


Given a 2D board and a word, find if the word exists in the grid.

The word can be constructed from letters of sequentially adjacent cell, where "adjacent" cells are those horizontally or]]></description><category></category></item><item><title><![CDATA[LeetCode:Rotate Array]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45722589</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45722589</guid><author>yao_wust</author><pubDate>Thu, 14 May 2015 16:29:28 +0800</pubDate><description><![CDATA[题目描述：


Rotate an array of n elements to the right by k steps.

For example, with n = 7 and k = 3, the array [1,2,3,4,5,6,7] is
 rotated to [5,6,7,1,2,3,4].

思路分析：将数组分为左右两部分，先将左右两部分各自翻转，最后再将整个]]></description><category></category></item><item><title><![CDATA[LeetCode:Reverse Bits]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45722169</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45722169</guid><author>yao_wust</author><pubDate>Thu, 14 May 2015 15:59:54 +0800</pubDate><description><![CDATA[题目描述：


Reverse bits of a given 32 bits unsigned integer.

For example, given input 43261596 (represented in binary as 00000010100101000001111010011100), return 964176192 (represented in binary a]]></description><category></category></item><item><title><![CDATA[LeetCode:House Robber]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45721591</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45721591</guid><author>yao_wust</author><pubDate>Thu, 14 May 2015 15:31:16 +0800</pubDate><description><![CDATA[题目描述：


You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adj]]></description><category></category></item><item><title><![CDATA[LeetCode:Binary Tree Right Side View]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45671653</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45671653</guid><author>yao_wust</author><pubDate>Tue, 12 May 2015 16:50:10 +0800</pubDate><description><![CDATA[题目描述：


Given a binary tree, imagine yourself standing on the right side of it, return the values of the nodes you can see ordered from top to bottom.

For example:
Given the following binary tr]]></description><category></category></item><item><title><![CDATA[LeetCode:Number of Islands]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45670959</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45670959</guid><author>yao_wust</author><pubDate>Tue, 12 May 2015 16:14:35 +0800</pubDate><description><![CDATA[题目描述：


Given a 2d grid map of '1's (land) and '0's
 (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacent lands horizontally or vertically. Y]]></description><category></category></item><item><title><![CDATA[LeetCode:Bitwise AND of Numbers Range]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45669977</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45669977</guid><author>yao_wust</author><pubDate>Tue, 12 May 2015 15:25:21 +0800</pubDate><description><![CDATA[题目描述：


Given a range [m, n] where 0 

For example, given the range [5, 7], you should return 4.

代码：
class Solution
{
	public:
		int rangeBitwiseAnd(int m,int n)
		{
			int i = 0;
			while(m ]]></description><category></category></item><item><title><![CDATA[LeetCode:Happy Number]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45645529</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45645529</guid><author>yao_wust</author><pubDate>Mon, 11 May 2015 16:37:43 +0800</pubDate><description><![CDATA[题目描述：


Write an algorithm to determine if a number is "happy".

A happy number is a number defined by the following process: Starting with any positive integer, replace the number by the sum of ]]></description><category></category></item><item><title><![CDATA[LeetCode:Remove Linked List Elements]]></title><link>https://blog.youkuaiyun.com/yao_wust/article/details/45645219</link><guid>https://blog.youkuaiyun.com/yao_wust/article/details/45645219</guid><author>yao_wust</author><pubDate>Mon, 11 May 2015 16:15:37 +0800</pubDate><description><![CDATA[题目描述：


Remove all elements from a linked list of integers that have value val.

Example
Given: 1 --> 2 --> 6 --> 3 --> 4 --> 5 --> 6, val = 6
Return: 1 --> 2 --> 3 --> 4 --> 5


思路分析：在链表头节点]]></description><category></category></item></channel></rss>