摘要: 第 2 章 辅助存储管理 磁盘的概念:圆盘、盘面、磁道、扇区 读写时间:读写某个磁盘块的时间 = 寻道时间 + 旋转延迟 + 传输时间;平均寻道时间是移动过整个磁盘的 1/3(证明);平均旋转延迟是磁盘旋转半周需要的时间 磁头调度:电梯算法 磁盘故障的应对技术:RAID(冗余盘)、RAID 4(奇偶 阅读全文
posted @ 2024-12-17 11:32 sysss 阅读(44) 评论(0) 推荐(0)
摘要: 《数据库》期中复习 只有两个重点:查询表的方法和设计表的模式。 第二章 关系数据模型 数据模型是用于描述数据或信息的标记,由数据结构、数据操作和数据上的约束条件组成。 一个关系的列被称为属性 attribute,关系名和其属性的集合称为关系的模式 schema,关系的每一行称为元组 tuple,元组 阅读全文
posted @ 2024-10-19 16:49 sysss 阅读(52) 评论(0) 推荐(0)
摘要: 使用 Menhir 构建 SimPL 的编译器 Lexer and Parser 语法分析模块 Lexer, Parser, AST 是三个依次耦合的模块,可以这么描述三者的关系: Lexer tokens--> Parser nodes--> AST 相对于上面的图像化描述,cs3110 反过来构 阅读全文
posted @ 2024-10-08 22:06 sysss 阅读(44) 评论(0) 推荐(0)
摘要: 下载 Dune opam install dune 创建项目 dune init project <project-name> 如果创建成功,有 Success: initialized project component named <project-name> 得到如下的一个文件结构 proje 阅读全文
posted @ 2024-10-06 21:36 sysss 阅读(174) 评论(0) 推荐(0)
摘要: (* Exercise: mutable fields *) type student = { name : string; mutable gpa : float; } let stuA = {name = "Alice"; gpa = 3.7} let () = stuA.gpa <- 4.0 阅读全文
posted @ 2024-10-05 11:40 sysss 阅读(10) 评论(0) 推荐(0)
摘要: (* Exercise: spec game *) (* Where is another programmer? *) (* Exercise: poly spec *) (* [Poly] represents immutable polynomials with integer coeffci 阅读全文
posted @ 2024-10-04 20:05 sysss 阅读(25) 评论(0) 推荐(0)
摘要: 背景 这几天突击了一下 Cornell 的 cs3110;抽了两个下午刷完了 Chapter 3,4,5 的课后习题,很有感触。结合自己浅薄的函数式编程理解和贫瘠的 JavaScript / TypeScript 开发经历,总结一下自己第一阶段的函数式编程学习经历。😃 从 JavaScript 出 阅读全文
posted @ 2024-10-03 21:43 sysss 阅读(54) 评论(0) 推荐(0)
摘要: (* Exercise: complex synonym *) module type ComplexSig = sig type complex val zero : complex val add : complex -> complex -> complex end (* Exercise: 阅读全文
posted @ 2024-10-03 19:43 sysss 阅读(16) 评论(0) 推荐(0)
摘要: (* Exercise: mystery operator 1 *) let ( $ ) f x = f x;; (* 使得函数的连续调用具有一部分右结合的特质 square $ 2 + 2 与 square 2 + 2 的运行结果分别是 16 和 6 *) (* Exercise: repeat 阅读全文
posted @ 2024-10-02 22:14 sysss 阅读(10) 评论(0) 推荐(0)
摘要: (* Exercise: list expressions *) let list1 = [1; 2; 3; 4; 5];; let list2 = 1 :: 2 :: 3 :: 4 :: 5 :: [];; let list3 = [1] @ [2; 3; 4;] @ [5];; (* Exerc 阅读全文
posted @ 2024-10-02 19:22 sysss 阅读(17) 评论(0) 推荐(0)