Lab4实验报告
Execrise 1
Implement mmio_map_region in kern/pmap.c.
// mmio_map_region()
uintptr_t ret = base;
size = ROUNDUP(size, PGSIZE);
base = base + size;
if (base >= MMIOLIM) {
panic("larg...
分类:
其他好文 时间:
2016-06-12 02:25:38
阅读次数:
438
基本写法 为了方便演示,这里使用Runtime.Cache做缓存容器,并定义个简单操作类。如下: 1 2 3 4 5 6 7 8 9 10 11 12 public class CacheHelper { public static object Get(string cacheKey) { ret ...
分类:
其他好文 时间:
2016-06-11 15:50:32
阅读次数:
191
Warning:array_filter()expectsparameter2tobeavalidcallback,function‘checkMonth‘notfoundorinvalidfunctionnameinpath\to\xxxModel.phponline36下面是相关的Code片段-php版本:5.6:functioncheckMonth($v){
return$v==$this->month;
}
functiongetByMonth($month){
$ret..
分类:
其他好文 时间:
2016-06-11 07:11:06
阅读次数:
546
Given an integer array, find a subarray with sum closest to zero. Return the indexes of the first number and last number. Given [-3, 1, 1, -3, 5], ret ...
分类:
其他好文 时间:
2016-06-09 22:19:04
阅读次数:
243
装饰器补充之双层装饰器 1 user_info = {} 2 3 4 def check_login(func): 5 def inner(*args, **kwargs): 6 if user_info.get('is_login', None): 7 ret = func(*args, **kw ...
分类:
编程语言 时间:
2016-06-07 19:07:10
阅读次数:
320
这里并没有对master和minion端配置文件的所有选项都进行说,而是挑常用的进行了说明。一、Master常用配置选项说明cat/etc/salt/masterinterface:指定bind的地址(默认为0.0.0.0)publish_port:指定发布端口(默认为4505)ret_port:指定结果返回端口,与minion配置文件中的ma..
分类:
其他好文 时间:
2016-06-07 16:37:56
阅读次数:
367
一、要求: 选课系统 管理员: 创建老师:姓名、性别、年龄、资产 创建课程:课程名称、上课时间、课时费、关联老师 使用pickle保存在文件 学生: 学生:用户名、密码、性别、年龄、选课列表[]、上课记录{课程1:【di,a,】} 1、列举所有课程 2、选择课程 3、学生上课, 4、ret = 课程 ...
分类:
其他好文 时间:
2016-06-05 15:29:06
阅读次数:
757
一、函数知识补充函数不设置值,默认返回None;函数中参数都是按引用传递,函数里修改了参数,原始参数也会修改。12345678910111213141516171819li = [11, 22, 33, 44] def f1(arg): arg.append(55) ret = f1(li) pri... ...
分类:
编程语言 时间:
2016-06-04 13:24:57
阅读次数:
327
1) 反汇编dll C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\ildasm.exe 打开dll文件,再转储。 2) 修改il文件 IL_0000: ldc.i4.1 IL_0001: ret相当于return true; 3) 编 ...
Q键连发。按住Q键则连发。松开则停止1。 1楼. 检测 按键按下,则允许某一段后台程序开始执行。 2楼. 获得后台输入窗口的 Hwnd。 子窗口要取子窗口的Hwnd。DX软件绘图的窗口,要用DX按键模式。 . 用API函数, ret = GetAsyncKeyState(81)来检测。 可以这样简单 ...
分类:
其他好文 时间:
2016-06-03 11:23:19
阅读次数:
828