Nội dung bài họcLesson content
Máy tính là gì?What is a computer?
Máy tính là một cỗ máy nhận lệnh từ con người và thực hiện theo đúng thứ tự. Khi bạn nhấn nút, gõ phím, hay chạm màn hình — bạn đang ra lệnh cho máy tính. Máy tính không tự biết làm gì, nó chỉ làm đúng những gì bạn bảo nó làm.A computer is a machine that receives commands from humans and executes them in order. When you press a button, type, or touch the screen — you are giving commands to the computer. The computer does not know what to do on its own; it only does exactly what you tell it to do.
Thuật toán là gì?What is an algorithm?
Thuật toán (algorithm) là một tập hợp các bước theo thứ tự để giải quyết một vấn đề. Ví dụ: công thức làm sandwich là một thuật toán — bạn làm theo từng bước: (1) lấy bánh mì, (2) phết bơ, (3) thêm phô mai, (4) ăn. Nếu đổi thứ tự bước, kết quả sẽ khác.An algorithm is a set of ordered steps to solve a problem. For example, a sandwich recipe is an algorithm — you follow each step: (1) get bread, (2) spread butter, (3) add cheese, (4) eat. If you change the order, the result will be different.
Tại sao thứ tự quan trọng?Why does order matter?
Máy tính làm việc theo thứ tự từ trên xuống dưới, từ trái sang phải. Nếu bạn bảo máy tính "ăn sandwich trước khi làm sandwich", nó sẽ không hiểu vì chưa có sandwich để ăn. Thứ tự đúng là: làm trước, ăn sau.Computers work in order from top to bottom, left to right. If you tell the computer "eat the sandwich before making it", it will not understand because there is no sandwich to eat yet. The correct order is: make first, eat later.
Trò chơi: Làm sandwich bằng lệnhGame: Make a sandwich with commands
Hãy tưởng tượng bạn là đầu bếp và bạn đang viết lệnh cho một robot làm sandwich. Viết 5 bước theo đúng thứ tự để robot có thể làm được một chiếc sandwich phô mai. Mỗi bước phải rõ ràng, không bị bỏ sót.Imagine you are a chef writing commands for a robot to make a sandwich. Write 5 steps in the correct order so the robot can make a cheese sandwich. Each step must be clear and not skipped.