Secondary 3 Information & Communication Technology

S3 ICT: advanced Python (dictionaries, files, OOP) with a small app project, database and SQL basics, hands-on HTML/CSS web design, and an introduction to AI — core concepts, ethics and practical experience. Every lesson comes with bilingual ICT vocabulary cards.

The order below is the recommended shallow-to-deep path.

Units 單元

Tap a unit name to jump to its topics.

程式設計進階 Programming II4/4 live

  1. 1Python dictionaries and setsAdvanced
  2. 2File handlingAdvanced
  3. 3Introduction to object-oriented programmingAdvanced
  4. 4Small application projectAdvanced
⚡ Unit quiz 快測5 Qs

Answer on your own first, then reveal — wrong answers go to your wrong-answer book.

Q1If phonebook = {"Mary": "9123 4567", "John": "6234 7789"}, what does phonebook["Mary"] give?

Q2Which open mode wipes the file's existing content? A. "r" B. "w" C. "a"

Q3Which is right about classes and objects? A. A class is the blueprint, an object an instance built from it B. An object is the blueprint, a class the instance C. They are identical

Q4The correct order for building a small application? A. code → test → design → requirements B. requirements → design → code → test C. design → code → requirements → test

Q5What does set([3, 1, 3, 2, 1]) give?

資料庫入門 Databases3/3 live

  1. 5Database conceptsFoundation
  2. 6Basic SQL queriesAdvanced
  3. 7Inserting, updating and deleting dataAdvanced
⚡ Unit quiz 快測5 Qs

Answer on your own first, then reveal — wrong answers go to your wrong-answer book.

Q1In a database table, what are a row and a column called?

Q2In SELECT * FROM students;, what does the * mean?

Q3A new student joins and needs a new record — which SQL? A. SELECT B. INSERT INTO C. UPDATE

Q4Which suits a students table's primary key best? A. name B. student number C. class

Q5To return only records scoring 80 or above, add which clause? A. ORDER BY B. WHERE score >= 80 C. SELECT 80

網頁製作 Web design3/3 live

  1. 8HTML structure and common tagsFoundation
  2. 9Styling pages with CSSFoundation
  3. 10Building a website projectAdvanced
⚡ Unit quiz 快測5 Qs

Answer on your own first, then reveal — wrong answers go to your wrong-answer book.

Q1Where does visible page content go? A. <head> B. <body> C. <title>

Q2In .highlight { background-color: yellow; }, what is .highlight?

Q3Which file does a browser load automatically at a site's address? A. home.html B. index.html C. main.html

Q4How many <h1> should a page normally have?

Q5What is the box model's order from the inside out?

人工智能入門 AI basics3/3 live

  1. 11Core concepts of artificial intelligenceFoundation
  2. 12AI ethicsAdvanced
  3. 13Hands-on with AI toolsAdvanced
⚡ Unit quiz 快測5 Qs

Answer on your own first, then reveal — wrong answers go to your wrong-answer book.

Q1Which nesting is right? A. deep learning ⊃ AI ⊃ machine learning B. AI ⊃ machine learning ⊃ deep learning C. unrelated

Q2What is the root cause of a hiring AI systematically downgrading women applicants?

Q3What is the text instruction typed into generative AI called?

Q4What separates training from inference?

Q5Which Hong Kong law governs collecting and using personal data? Name two of its requirements.

Vocabulary book 生字簿

All terms, bilingual (printable).

D
Dictionary字典

A structure storing data as key-value pairs, finding values by key, like a contacts book.

K
Key鍵

The name used to look up in a dictionary, e.g. "Mary" in {"Mary": "9123 4567"}.

V
Value值

The data a key points to, e.g. the phone number in {"Mary": "9123 4567"}.

K
Key-value pair鍵值對

The basic unit of a dictionary: one key joined to one value by a colon.

g
get()安全取值方法

Fetches by key and returns a default when the key is missing, e.g. d.get("x", 0).

i
items()鍵值對走訪

Returns all key-value pairs so a for loop can take key and value together.

i
in (membership test)成員檢查

Checks whether a key is in a dictionary or an item is in a set, giving True or False.

S
Set集合

An unordered collection with no duplicates, often used to deduplicate, e.g. set([1, 1, 2]) gives {1, 2}.

D
Deduplication去重

Keeping only one copy of each repeated item — the classic use of a set.

F
File handling檔案處理

Letting a program read and write files so data survives after the program ends.

o
open()開檔函數

The function that opens a file, given a filename and a mode, e.g. open("a.txt", "r").

M
Mode "r" / "w" / "a"讀取/寫入/附加模式

"r" reads only; "w" writes and wipes existing content; "a" appends at the end without destroying old data.

w
with ... as f自動關檔語法

Closes the file automatically when the with block ends — the recommended file pattern.

r
read() / readlines()讀取方法

read() returns the whole content as one string; readlines() returns a list of lines.

N
Newline character \n換行符

The special character meaning 'new line'; add it yourself in write(), strip it off lines you read.

C
CSV逗號分隔值檔

A plain-text data format with comma-separated fields, one record per line, openable in Excel.

s
split(",")分割字串

Splits a string at commas into a list, e.g. "Mary,85".split(",") gives ["Mary", "85"].

t
try-except異常處理

Putting risky code in try and handling named exceptions in except so the program keeps running.

C
Class類別

The blueprint defining a kind of object's data and behaviour, e.g. a Student class.

O
Object物件

An instance built from a class, holding its own attributes, e.g. Mary's Student object.

A
Attribute屬性

Data stored inside an object, e.g. s1.name, s1.cls.

M
Method方法

A function belonging to the object, defined inside the class, e.g. introduce().

_
__init__ (constructor)建構子

The special method run automatically when an object is created, setting starting attributes.

s
self自身引用

The first parameter of every method — the object being called — used to reach its own attributes.

I
Instance實例

Another word for object: one individual actually produced by a class.

I
Instantiate實例化

The act of creating an object from a class, e.g. s1 = Student("Mary", "3A").

E
Encapsulation封裝

Keeping data and the methods that use it inside one class, hiding internal details.

R
Requirements analysis需求分析

The stage deciding what the program must do and for whom, ending with a clear feature list.

D
Design設計

Planning the data structure, the split of functions and the interface before coding.

I
Implementation編寫實作

Writing the code function by function following the design, testing as you go.

T
Testing測試

Verifying the program against requirements with normal and extreme inputs.

M
Menu選單

An interface listing numbered features for the user to pick, shown repeatedly inside a while loop.

I
Input validation輸入驗證

Checking that user input is sensible (e.g. a score must be a number) and asking again when not.

M
Modular design模組化設計

Splitting a program into small functions with single jobs, easy to write, test and change.

B
Boundary case邊界情況

The extremes most often overlooked, such as empty lists, zero scores or duplicated names.

D
Documentation文件說明

Recording what the program does, how to use it and why it was designed that way.

D
Database資料庫

A system storing and managing large amounts of data in an organised way for searching, updating and error prevention.

T
Table資料表

The two-dimensional structure holding one kind of data, made of rows (records) and columns (fields).

R
Record記錄

One row of a table — all the data of a single individual, e.g. one student.

F
Field欄位

One column of a table — a single attribute of the data, e.g. name, class.

P
Primary key主鍵

The field uniquely identifying each record — never repeated, never empty, e.g. student number.

R
Relational database關聯式資料庫

A database of tables linked by shared fields, e.g. a scores table joining the students table by student number.

D
DBMS資料庫管理系統

The software managing a database — access, permissions and searching — e.g. MySQL, SQLite.

Q
Query查詢

A request made to a database, e.g. 'list all students in 3A', usually written in SQL.

D
Data redundancy資料冗餘

The same data stored in several places, which easily causes inconsistency after updates.

S
SQL結構化查詢語言

The standard language for talking to databases — querying, inserting, updating and deleting data.

S
SELECT選取關鍵字

The SQL keyword choosing which fields to return; SELECT * means all fields.

F
FROM來源表關鍵字

The SQL keyword naming which table the data comes from.

W
WHERE條件篩選

Sets a condition so only matching records return, e.g. WHERE score >= 80.

C
Comparison operator比較運算子

The symbols compared in WHERE: =, >, <, >=, <=; SQL tests equality with a single =.

A
AND / OR邏輯組合

Combines conditions: AND requires all to hold; OR requires any one.

O
ORDER BY排序

Sorts results by a field: DESC high to low, ASC low to high (the default).

L
LIMIT限制筆數

Returns only the first few rows, e.g. LIMIT 3 for the top three after sorting.

W
Wildcard *星號萬用字

The star after SELECT, meaning every field of the table.

I
INSERT INTO新增語句

The SQL statement adding a new record to a table, with VALUES supplying each field.

V
VALUES值清單

The part of INSERT giving actual values in field order, e.g. VALUES (2023011, 'Amy', '3A', 88).

U
UPDATE ... SET修改語句

The SQL statement changing field values of existing records; SET gives the new value, WHERE limits the scope.

D
DELETE FROM刪除語句

The SQL statement removing records from a table; WHERE decides which — omit it and every record goes.

S
Scope of WHEREWHERE 影響範圍

WHERE decides which records an UPDATE/DELETE touches; leaving it out means all records — very dangerous.

D
Data integrity資料完整性

Data staying correct and consistent, guarded by primary keys, field types and range rules.

P
Primary key constraint主鍵限制

The database refusing inserts that duplicate or omit the primary key, keeping every record identifiable.

B
Backup備份

An advance copy of the data, restorable after a mistake or an incident.

V
Verify驗證

Running SELECT after a write to confirm the result — the last step of the safe routine.

H
HTML超文字標記語言

The markup language behind web pages, using tags to describe content's structure and meaning.

T
Tag標籤

A marker in angle brackets, mostly in pairs: opening <p>, closing </p>.

E
Element元素

The whole of an opening tag, its content and the closing tag — <p>Hello</p> is one paragraph element.

A
Attribute屬性

Extra information inside an opening tag, e.g. href on <a href="...">, src and alt on <img>.

h
head / body頁首區/內容區

head holds information for the browser (title, encoding); body holds everything shown to visitors.

H
Hyperlink <a>超連結標籤

The link tag whose href gives the destination, e.g. <a href="https://...">go</a>.

I
Image <img>圖片標籤

A single tag: src names the image file, alt carries the description text.

S
Semantic tags語意化標籤

Structure tags declaring purpose: header, nav, main, footer.

N
Nested structure巢狀結構

Tags inside tags, layer by layer; the first opened closes last, never crossing.

C
CSS層疊樣式表

The language describing how pages look — colour, fonts, spacing and layout.

S
Selector選擇器

The opening part naming which elements a style hits, e.g. p, .highlight, #title.

C
Class selector類別選擇器

Starts with a dot (.highlight) and hits every element carrying that class — reusable anywhere.

I
ID selectorID 選擇器

Starts with a hash (#title) and hits the single element with that id on the page.

P
Property and value屬性與值

The two halves of a declaration: the property names what changes (color), the value what it becomes (red), ending with a semicolon.

B
Box model盒子模型

Every element is a box: content, padding, border, margin — four layers inside out.

P
Padding / Margin內邊距/外邊距

padding is the space inside, between content and border; margin is the space outside, to other elements.

H
Hex colour十六進制顏色碼

A six-digit colour code after #, e.g. #f07f2e orange, #ffffff white.

M
Media query媒體查詢

@media (max-width: 600px) { ... } applies styles only under a screen width — the basis of responsive design.

S
Site map網站地圖

The page list and link plan drawn before building — which pages exist and how they connect.

i
index.html主頁檔案

The site's default front door, loaded automatically when a visitor opens the folder.

N
Navigation bar導覽列

The link menu present on every page (usually inside nav), letting visitors reach any page.

R
Relative path相對路徑

A path measured from the current file, e.g. about.html on the same level, images/p1.jpg in a subfolder.

f
figure / figcaption圖文配對標籤

figure wraps the image and figcaption carries its caption, keeping picture and description together.

C
Consistent layout一致版面

The shared header, nav, footer and styles across pages, making the site look professional and unified.

A
Accessibility無障礙

Design usable by everyone including blind users: alt text, ordered headings, strong colour contrast.

S
SEO搜尋引擎最佳化

Practices helping search engines understand and recommend a page: clear titles, meta description, keywords.

M
Meta description網頁簡介標籤

A one-line summary in head, often shown directly in search results.

A
Artificial Intelligence (AI)人工智能

Technology letting machines perform tasks needing human intelligence, e.g. speech, vision and translation.

M
Machine Learning機器學習

The mainstream approach to AI: no hard-coded rules — computers derive patterns from mass examples.

D
Deep Learning深度學習

A branch of machine learning using brain-like neural networks, strong at images, speech and language.

N
Neural network神經網絡

A layered computing structure imitating brain connections — the building block of deep learning.

T
Training訓練

The stage teaching a model with mass examples: predict, check, adjust parameters, repeat.

I
Inference推斷

The stage where a trained model answers new inputs.

M
Model模型

The trained product: it holds the learned patterns and parameters and judges new inputs.

D
Dataset資料集

The batch of examples used in training, e.g. a hundred thousand photos labelled cat or dog.

H
Hallucination幻覺

An AI stating falsehoods in confident prose — it tracks patterns, not truth.

A
Algorithmic bias演算法偏見

Systematic unfairness in an AI caused by unbalanced training data.

P
Personal data個人資料

Data identifying an individual, e.g. name, facial image, voice, address, phone number.

P
PDPO個人資料(私隱)條例

Hong Kong's law on collecting and using personal data: state the purpose, collect minimally, access and correct.

D
Deepfake深度偽造

AI-generated or altered media that passes as real — swapped faces, imitated voices.

M
Misinformation虛假資訊

Content that is untrue; AI hallucinations and deepfakes both produce it.

A
Academic honesty學術誠信

The principle of declaring sources honestly and never passing off others' (or AI's) work as your own.

C
Consent同意

Voluntary permission after the person knows the use; uploading someone's photo without it breaches their rights.

T
Transparency透明度

AI systems should disclose their data sources, workings and limits to users.

A
Accountability問責

When AI causes harm, a clear person or body must answer for it — never 'the AI did it'.

G
Generative AI生成式人工智能

AI that creates new content — text, images, music, video — e.g. chatbots and text-to-image tools.

P
Prompt提示詞

The text instruction given to generative AI; how specific it is directly shapes the output.

P
Prompt engineering提示工程

The craft of designing and refining prompts for better outputs — being specific, assigning roles, iterating.

T
Text-to-image文生圖

AI tools generating images from text, e.g. 'Lion Rock at dusk, watercolour style'.

I
Iteration迭代

Repeated follow-ups and prompt tweaks, nudging the AI output toward the ideal step by step.

F
Fact-check事實查核

Verifying AI's facts and figures against reliable sources such as textbooks and official sites.

T
Tool comparison工具比較

Knowing each AI tool's strengths and blind spots and choosing per task.

C
Critical verification批判性驗證

Treating AI output as a draft: check facts, test logic, watch for hallucinations before adopting.

D
Data disclosure資料輸入守則

Never type personal data, passwords or others' private details into AI tools — inputs may be retained.

More units rolling out in batches — same illustrated format.