| English | 释义 | 拼音 |
|---|---|---|
| algorithm/ˈælɡərɪθəm/ | 算法 | suàn fǎ |
| finite/ˈfaɪnaɪt/ | 有限的 | yǒu xiàn de |
| sequencing/ˈsiːkwənsɪŋ/ | 顺序 | shùn xù |
| flowchart/ˈfləʊtʃɑːt/ | 流程图 | liú chéng tú |
| natural language/ˈnætʃərəl ˈlæŋɡwɪdʒ/ | 自然语言 | zì rán yǔ yán |
| same result/seɪm rɪˈzʌlt/ | 相同结果 | xiāng tóng jié guǒ |
| refine/rɪˈfaɪn/ | 改进 | gǎi jìn |
| efficient/ɪˈfɪʃənt/ | 高效 | gāo xiào |
什么是算法?
- 一个算法(algorithm)是一个有限的(finite)、分步的指令集合,用来完成一个任务。
- "有限"意味着它总在有限数量的步骤后结束。
- 一份食谱、一条去学校的路线、一种排序方法都是算法。
- 每个程序都由算法构建。
An algorithm is:
难度 1/5 · 今日首次完成可获 100 金币及少量额外奖励
"Finite" means it always ends after a limited number of steps.
三个构件
- 每个算法都能由三个基本结构构建:
- 顺序(sequencing):一个接一个地做步骤;
- 选择:在路径间选择;
- 迭代:重复步骤。

流程图(Flowchart)使用标准符号展示算法流程
Sequencing, selection, or iteration?
Every algorithm is built from three structures: sequencing (steps in order), selection (choosing a path), and iteration (repeating steps).
Which are the three building blocks of algorithms? (Select all that apply)
难度 2/5 · 今日首次完成可获 140 金币及少量额外奖励
Sequencing, selection, and iteration build every algorithm.
A flowchart, pseudocode, and natural language can all express:
难度 1/5 · 今日首次完成可获 100 金币及少量额外奖励
All three describe the same steps differently.
Two different algorithms can never produce the same correct result.
难度 1/5 · 今日首次完成可获 100 金币及少量额外奖励
False. Different algorithms can solve the same problem correctly; one may simply be faster than the other.
表达它的方式
- 你可以用伪代码、流程图(方框和箭头)或简单的自然语言来表达算法。
- 这三种以不同形式描述相同的步骤。
- 不同的算法能给出相同结果(same result)——一个短但慢,另一个长但快。
- 如果两者都给出正确答案,谁也不"更正确"。
The "largest of three" algorithm runs on a=4, b=9, c=6. What does it output?
难度 2/5 · 今日首次完成可获 140 金币及少量额外奖励
Start 4; 9 > 4 → 9; 6 > 9 is false → stays 9.
Improving an algorithm step by step to be correct, clear, and efficient is called ______.
难度 1/5 · 今日首次完成可获 100 金币及少量额外奖励
Refining follows testing, making the algorithm better each pass.
为效率而改进
- 我们改进(refine)一个算法,让它正确、清晰、高效(efficient)。
- 改进意味着在测试后一步步改善它。
三个中的最大。 largest ← a;IF b > largest:largest ← b;IF c > largest:largest ← c;DISPLAY largest。对 a=4、b=9、c=6:开始 4;9 > 4 → largest 9;6 > 9 为假 → 保持 9。输出 9。这用了顺序和选择。
一个算法是一个有限的步骤集合,由三个结构构建:顺序、选择和迭代。你能把它表达为伪代码、一个流程图或自然语言。不同的算法能给出相同结果,所以我们改进它们,让它们正确、清晰、高效。