code programming

从空白开始学 Python

九位学生已经走过的确切步骤,从空白文件到一个能提问、检查答案并拒绝错误输入的程序。无需编程基础。无需数学。你会故意反复出错。

  • trending_upBeginner
  • schedule5h 43m
  • menu_book12 节课程
  • publicEnglish
  • bolt免费池
从空白开始学 Python

课程概述

大多数初级课程会向你展示可用的代码,让你欣赏它。这门课程植入 bug 并让它触发。 你将在四个模块中写一个程序。它以单行 `print` 开始,最后变成能够提问、清理用户输入、判断如何处理、对其进行算术运算、拒绝无意义的输入,并循环到满意为止的程序。你在途中遇到的每个故障都是真实学生首先遇到过的:尾部空格、大写字母、缺失冒号、忘记存储的结果、暗地里是文本的数字。 最后你不会背诵 Python。你将能够找出为什么某些东西不起作用,这才是真正的工作。

课程大纲 · 4 个模块

lock解锁权限内容
  1. 01 初次接触
    3 节课程·1h 13m

    这里没有任何概念性的内容。你输入,运行,读取计算机返回的信息。这个模块唯一要训练的技能是阅读错误消息,而不是对它感到恐慌。

  2. 02 函数和决策
    3 节课程·1h 27m

    这个模块中有两条规则,它们在你的 Python 生涯中始终适用。所有定义在上方,所有调用在下方。缩进就是想象中的括号——计算机通过计数空格来决定什么属于什么。

  3. 03 清理用户输入
    3 节课程·1h 8m

    脏盘子要先放进水槽再放进橱柜。任何用户的输入都必须经过 clean() 函数处理后,才能进入你的逻辑。

  4. 04 数字、验证和循环
    3 节课程·1h 55m

    垃圾进,垃圾出。input() 总是给你文本,即使看起来像数字,而相信它的程序就是在别人面前崩溃的程序。

常见问题

我将在 从空白开始学 Python 中学到什么?
九位学生已经走过的确切步骤,从空白文件到一个能提问、检查答案并拒绝错误输入的程序。无需编程基础。无需数学。你会故意反复出错。
我需要有先前的经验吗?
不需要 — 从空白开始学 Python 从基础开始,适合初学者。
从空白开始学 Python 需要多长时间?
从空白开始学 Python 包含 4 个模块和 12 节课程。您可以按自己的速度学习。
我如何获得访问权限?
从空白开始学 Python 属于免费池 — 创建免费账户并将其添加到您的收藏。

更多 编程 课程

First Program — Scratch for ages 5–9
Beginner First Program — Scratch for ages 5–9 Nine Scratch blocks, three sessions of about twenty-five minutes, and one small program a child of five to nine builds themselves. Written for the parent sitting beside them: what to click, what they will get stuck on, what to say when it goes wrong, and when to keep your hands off the mouse.
Binary, Hex and Data Units
Beginner Binary, Hex and Data Units The topic that costs more marks than any other on the paper, taught by hand. Bits and bytes, binary and hex in all six directions, the 1000-versus-1024 trap, file sizes, transmission times, overflow, two's complement and character sets. Every module ends in a timed drill marked the way an examiner marks it.
AI Without the Hype
Beginner AI Without the Hype What the model is actually doing when it answers you, why that produces something that looks like thinking, why it invents citations, and the cost mechanic almost nobody explains: a chat resends the entire conversation on every single turn. You will do the arithmetic yourself.
IGCSE and GCSE Computer Science — Theory That Actually Gets Marked
Intermediate IGCSE and GCSE Computer Science — Theory That Actually Gets Marked The theory half of the paper, taught so it survives the exam room. The memory hierarchy and what actually happens at boot. Compilers, interpreters and assemblers, including the answer that sounds right and scores nothing. Databases from a spreadsheet up to keys and normalisation. DNS and the full path between pressing Enter and seeing the page. Systems software, and the ethical and legal section that is the easiest ten marks on the paper.
Programming for the Exam — Python Answers That Score
Intermediate Programming for the Exam — Python Answers That Score The programming half of the paper, taught at exam pitch. Pseudocode translated both ways, because the mark scheme is written in a notation nobody practises. Trace tables done column by column, including the ones with a loop and a condition inside it. Linear and binary search, bubble and insertion sort, what each costs and the comparison questions boards love. Validation against verification, and the boundary test data everybody forgets. Procedures against functions, and a systematic method for finding your own error with four minutes left.
AI at Your Desk
Beginner AI at Your Desk You have an office job, you are losing hours a week, and you do not care how any of this works. Four tasks from your own week, each done twice and timed. A fifth you should not have handed over. You finish with real work done and a page of your own numbers you can show someone.