关于VFS的通用读,我们不做考虑,本文以如下函数为根,往下分析:do_generic_mapping_read(*ppos,*mapping,*desc)本函数的目的是,从磁盘读数据到用户态,先是从*ppos开始的页,一直读到*ppos+desc->count 为止的,这么多个页,然后拷贝desc-...
分类:
其他好文 时间:
2014-07-16 21:53:13
阅读次数:
326
原题: ZOJ 3769http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3769一个带有一些限制的背包问题。假设在没有限制的情况下,那么定义:dp[i][j]表示在前 i 类物品中,总的Toughness为 j 的时候最大的伤...
分类:
其他好文 时间:
2014-07-16 20:45:58
阅读次数:
132
原题:ZOJ 3774 http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3774-------------------------------------------------------------------------...
分类:
其他好文 时间:
2014-07-16 20:45:49
阅读次数:
137
用于打印杨辉三角的程序,有多种算法仅提供一种PRogram yh (input,ouput);var m,n,c:integer;BeginFor m:=0 TO 10 Do Begin c:=1; write(c:40-3*m); For n:=1 To m Do begin c:=c+(m-n+...
分类:
其他好文 时间:
2014-07-16 19:38:04
阅读次数:
148
All good so far. We next want to delete the branch on github. However, if we do this the naive way:git push origin :masterwe just get an error like th...
分类:
其他好文 时间:
2014-07-16 19:33:09
阅读次数:
231
What you need to do is edit the configure file. And find out this:SLIBNAME='$(SLIBPREF)$(FULLNAME)$(SLIBSUF)'SLIBNAME_WITH_VERSION='$(SLIBNAME).$(LIBV...
分类:
其他好文 时间:
2014-07-14 00:00:03
阅读次数:
278
BT5与Ubuntu下安装最新版Metasploit4.5方法:(先把老版本的MSF uninstall,BT5自带的老版本Metasploit没有办法升级!)1、下载Metasploit下的Linux安装包,拷贝至Ubunto的/opt目录。http://www.metasploit.com/do...
分类:
Web程序 时间:
2014-07-13 12:25:55
阅读次数:
312
题目请见 http://download.csdn.net/download/wangpegasus/5701765
第四章以下通过VS2012
1、
#include "stdafx.h"
#include
double sqrt(double temp)
{
double before, after;
before = 1.0;
after = 1.0;
do
{...
分类:
其他好文 时间:
2014-07-12 23:19:41
阅读次数:
225
第四章——语句(上)
总结总结!!!
C没有布尔类型,所以在一些逻辑判断时候必须用整型表达式,零值为假,非零值为真。
for比while把控制循环的表达式收集起来放在一个地方,以便寻找。
do语句比while语句类似,但是前者能够保证循环体至少执行一次。
不要用goto。
switch...case...在没有加break时候多半有问题,我有一篇文章曾专门说这个事儿。
详情见http...
分类:
其他好文 时间:
2014-07-12 18:30:43
阅读次数:
135
原题:ZOJ 3681http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3681题意:给一个m,n,m表示m个人,可以把m个人分成k组,每组m/k个人,人数要一样,如果超过一半的组支持Italy的话,说明这n个人都支持Italy...
分类:
其他好文 时间:
2014-07-12 15:18:56
阅读次数:
166