COMP1511 Exam 2 急救路线图
非 UNSW 官方材料。本文基于官方课程主页、strings/2D arrays 相关 lecture、Debugging Guide 和 Style Guide 做中文转述;不复制真实考试题正文。[S001][S013][S014][S015][S004][S005]
今天只做:string、2D array、struct array 各过一遍。 下一步:主控台 · 第 5 课 · 练习菜单 别乱跳:第二次先保逐字符和 row/col。
先把目标缩小
Exam 2 先按 strings、2D arrays、structs、functions、assignment-style debugging 来准备;这和本站 AGENTS 规则一致,也贴合官方 Week 04/05 内容走向。[S013][S014][S015]
| 优先级 | 练什么 | 过关线 |
|---|---|---|
| 1 | string 逐字符 | 能停在 '\0' |
| 2 | 2D array | 能 row/col 双循环 |
| 3 | struct array | 能读 items[i].field |
| 4 | debugging | 能分清错误类型 |
今日 3 轮
每轮 25 分钟,只做一件事。不要同时开 lecture、lab、答案和聊天窗口。[S001]
- 看第 5 课。
- 做 1 道 string 或 2D array 题。
- 写 1 条错因。
考前速查
官方 Debugging Guide 建议先分类错误;Exam 2 也按 compile、autotest、run time、logic 的顺序查。[S004]
- 编译不过:看第一条错误。
- 输出不对:看空格、换行、大小写。
- 2D array 错:检查 row/col 有没有写反。
- string 错:检查有没有越过
'\0'。
引用
- [S001] COMP1511 course homepage: https://cgi.cse.unsw.edu.au/~cs1511/current/
- [S004] COMP1511 Debugging Guide: https://cgi.cse.unsw.edu.au/~cs1511/26T1/resources/debugging_guide.html
- [S005] COMP1511 Style Guide: https://cgi.cse.unsw.edu.au/~cs1511/26T1/resources/style_guide.html
- [S013] Lecture 7 PDF: https://cgi.cse.unsw.edu.au/~cs1511/26T1/slides/week_4/COMP1511_26T1_Lecture07.pdf
- [S014] Lecture 8 PDF: https://cgi.cse.unsw.edu.au/~cs1511/26T1/slides/week_4/COMP1511_26T1_Lecture08.pdf
- [S015] Lecture 9 PDF: https://cgi.cse.unsw.edu.au/~cs1511/26T1/slides/week_5/COMP1511_26T1_Lecture09.pdf