Мазмунга өтүү

Бул сабак азырынча кыргыз тилине которула элек, ошондуктан англис тилинде көрсөтүлдү.

Сабактын башталышы

An Address Is Also a Number

The memory lesson said it in passing: cells are numbered, and the number of a cell is its address. Today that innocent remark detonates. Addresses are numbers — and everything the course has established about numbers instantly applies to them: they can be stored in cells, and they can be computed. Half of the machinery of programming falls out of those two clauses.

Learning goals: explain what it means for a cell to hold the address of another cell; show that "being an address" is a reading, not a property; and demonstrate address arithmetic — reaching a cell nobody named in advance.

Start with the question

Cell 7 holds the number 100. Question: what is in cell 7?

After the agreement lesson you know to answer carefully: the number 100, and nothing else — meanings depend on the reader. But consider one particular reading agreement, modest-looking and world-carrying: "the number in cell 7 is the address of the cell I actually care about." Under this agreement, cell 7 does not hold a quantity — it holds a direction: "go to cell 100". A number read this way is universally called a pointer (or reference) — one word to learn, a lifetime of use.

cell 7 100 cell 100 45 "the thing I mean lives THERE" The arrow is not stored anywhere. Cell 7 holds 100; the arrow exists in the reading.

Say the crucial sentence aloud: the machine stores no arrows. Cell 7 holds the number 100 — a perfectly ordinary number that another reader could take for a temperature. The pointing is a reading agreement, exactly like "letter" or "brightness" — and like them it can be applied, withheld, or (with consequences a later tier will relish) misapplied.

Бул сабакты YourAIZone платформасында улантыңыз

Толук сабакта — толук түшүндүрмө, чыгарылган мисалдар, көп кездешкен каталар, заматта текшерилүүчү тесттер жана ЖИ-репетитор. Конок катары дароо баштаңыз же прогрессти сактоо үчүн аккаунт түзүңүз.

Толук сабакта

  • Толук түшүндүрмө
  • Чыгарылган мисалдар
  • Көп кездешкен каталар жана алардан кантип качуу керек
  • Тест суроолору: 2
  • Тема боюнча суроолорго жооп берген ЖИ-репетитор
  • Окуучу, ата-эне жана мугалим үчүн прогрессти көзөмөлдөө