初级Beginner点子Idea
管道被偷听:在全班面前说悄悄话
Someone Is Listening: Whisper in Front of the Class
凯撒密码、数字母来破解,再用“混颜料”在全班面前约定一把只有两个人知道的钥匙。
Caesar ciphers, cracking them by counting letters, and mixing paint to agree on a key in front of everyone.
这是一个课程点子:活动和资料都有,学习单还没做。
This is a lesson idea: the activities and links are ready, the worksheets are not made yet.
有人在管道中间偷看你们的 0 和 1。你能当着全班的面,把一句只有好朋友看得懂的话传过去吗?
Someone is peeking at the 0s and 1s in the pipe. Can you send a message, in front of the whole class, that only your friend can read?
孩子做什么What kids do
- 凯撒密码:每个字母往后移 3 位(A → D),两人互发密信。Caesar cipher: shift every letter 3 places (A → D) and swap secret notes.
- 破解:给一段长密文,不说移了几位。数一数哪个字母最多(英文里最常见的是 E)。Crack it: take a long secret message without the shift. Count which letter appears most (in English it is usually E).
- 难题:两个人从没见过面,怎么约定钥匙?用“混颜料”演示:公开的颜色加上各自的秘密颜色,交换后再加一次,两人得到同一种颜色。The hard part: two people who have never met agree on a key. Show it with paint: a public color plus each person’s secret color, swap, add your secret again, and both end up with the same color.
要点Key idea
凯撒密码的钥匙太少、字母频率又藏不住,所以好破。浏览器地址栏的“小锁”用的就是“公开交换也不怕”的方法(公钥密码)。
A Caesar cipher has too few keys and can’t hide letter frequencies, so it is easy to crack. The little lock in your browser uses a method that stays safe even when the exchange is public (public-key cryptography).
和 AI 的关系Where AI comes in
破解凯撒密码靠的是统计语言的规律,语言模型学的也正是这种规律。
Cracking a Caesar cipher uses the patterns of a language, which is exactly what language models learn.
视频与文章Videos and reading
- Crash Course CS #33: Cryptography 13 分钟:凯撒密码 → 频率分析 → 公钥13 min: Caesar → frequency analysis → public keys
- Art of the Problem: Diffie-Hellman Key Exchange 9 分钟,混颜料的动画9 min, the paint-mixing animation
- Classic CS Unplugged: Public Key Encryption 不插电活动unplugged activity