Lingnan University · FACULTY OF COMPUTER SCIENCE

CDT501 Computer Systems and Programming Basics

- one subject, every graph, every model, every mark
8 Chapters44-page Bible
Our own words - no uploaded lecturer files
Updated for this semester
The Complete Study & Assessment Guide ·

CDT501 Overview

Computer Systems and Programming Basics
— Trace the state, test the boundary, explain the result.
  • Lingnan University
  • Term 1, 2026-27
  • Postgraduate course
  • Computer Science
  • Assessment guide

What this course asks you to build

CDT501 introduces computer systems and programming for students with limited prior experience. The published course description connects programs, programming languages and execution on a computer, then develops statements, operators, variables, types, control structures and functions.

  • Assessment Assignments and in-class discussion and the group project each carry thirty per cent; the individual final paper carries forty per cent.
  • Core method Predict state and type before execution, then test the boundary that would make a plausible wrong program disagree.
  • Group mark The teacher group score supplies eighty per cent of the project result and the contribution score supplies twenty per cent.
  • Final submission Show a reproducible technical implementation and original analysis that clearly extends beyond the group foundation.
CDT501 · Lingnan University
An independent, AskSia-authored study guide. AskSia is not affiliated with, endorsed by, or sponsored by Lingnan University; the course code and name are used for identification only.
Assessment

How CDT501 is assessed

ComponentWeightFormat
Assignment and In-class discussion30%Weekly assignments on Moodle and participation in class
Group project30%Report and presentation; 80% teacher group mark plus 20% contribution score
Final paper40%Maximum 10 pages excluding references, with technical implementation and original analysis

The course introduction publishes these three weighted components and they total 100%. It consistently names the final component Final paper and gives paper requirements and submission timing. Attendance is a separate published condition requiring at least 80 percent of scheduled classes. Falling below 80 percent may prevent a student from satisfying the attendance pass condition and may lead to an F; consult the course Moodle page for its course-specific application. The generic attendance paragraph uses different assessment-access terminology, so this guide preserves that conflict without changing the Final paper label.

Assessment structure

30%30%40%AssignmentsGroup projectFinal paper

The segment widths reproduce the published weights and sum to 100%.

Current dates · verify in LMS

Current CDT501 dates

DateItemControl
3 or 6 December 2026Final paperThe course schedule and final-paper guidance give section-specific submission timing in the final teaching session.
6 December 2026Group report and slidesThe course introduction gives this date for the final group materials.

Dates are as published in the published course introduction and section schedules for the current offering. Confirm exact deadlines and submission settings in the live LMS.

Contents · every chapter, one map

What CDT501 covers

Eight chapters move from computer components and program execution through Python state, collections, decisions, loops and objects to a reproducible data-analysis pipeline.

01

Computer Systems and Execution

data paths through processor, memory, storage and network services

Follow the data before naming the fault

This chapter treats a computer as cooperating parts.

  • Input, processing, output and storage
  • CPU fetch-decode-execute cycle
  • RAM versus persistent storage
  • Workload bottlenecks and parallel engines
  • Client-server requests and responses
02

Programming Meaning and Environments

syntax, semantics, Python tools, notebook state and reproducibility

Separate valid syntax from correct meaning

This chapter distinguishes language grammar, execution meaning and fit with the actual problem.

  • Syntax, semantics and intent
  • Python and other language roles
  • Editors, IDEs and notebooks
  • Hidden notebook state
  • Minimal reproducible debugging reports
03

Variables, Types and Expressions

assignment state, numeric operators, conversion and weighted calculations

Make state changes visible

This chapter treats assignment as evaluation followed by rebinding.

  • Variable names and bindings
  • Assignment and augmented assignment
  • Numeric and string types
  • Explicit input conversion
  • Weighted calculations with intermediate values
04

Strings, Lists and Mutability

indexing, slicing, aliases, copies and collection choice

Access by position, change by identity

This chapter draws slice bounds as cuts between characters, with an included start and excluded stop.

  • Zero-based and negative indexing
  • Stop-exclusive slicing
  • Immutable strings
  • List methods and aliases
  • Copies and collection selection
05

Functions, Decisions and Boundary Tests

return values, Boolean logic, branch order and edge-case testing

Turn verbal rules into testable contracts

This chapter separates returned values from printed output, maps positional arguments to parameters and translates verbal intervals into ordered if-elif-else conditions.

  • Function inputs and return contracts
  • Print versus return
  • Comparisons and Boolean logic
  • If, elif and else ordering
  • Boundary and exception tests
06

Loops, Dictionaries and State

termination, ranges, nested iteration and exact-key lookup

Prove progress and make lookup exact

This chapter represents a loop as initial state, condition, body and update. It selects for when an iterable already describes the repetitions and while when continuation depends on changing state.

  • While-loop progress and termination
  • For loops and stop-exclusive ranges
  • Nested loop counts
  • Dictionary keys and updates
  • Nested collection shapes
07

Classes, Inheritance and Composition

instances, self, method lookup, parent construction and ownership

Trace ownership through every dot

This chapter binds self to one concrete receiver and separates class definitions from independent instances.

  • Classes and independent instances
  • Self and instance attributes
  • Method calls and returned values
  • Inheritance and parent initialisation
  • Composition and object ownership
08

NumPy, pandas and Visualisation

data shape, split-apply-combine, chart choice and reproducibility

Keep the table visible behind the picture

This chapter compares numerical arrays with labelled DataFrames, then builds a load, inspect, transform and visualise pipeline.

  • NumPy arrays and shapes
  • Pandas DataFrames and types
  • Groupby split-apply-combine
  • Chart choice and visual encodings
  • Reproducible analysis pipelines

Its learning outcomes extend that foundation into computer literacy, language comparison, procedural and object-oriented solutions, debugging, coding conventions and best practice.

The guide follows that progression by asking one question repeatedly: what state exists now, and which operation changes it?

How the chapters fit together

The first chapter follows data through input, memory, the processor, output, storage and network services.

The second separates syntax from semantics and shows how an editor, IDE, Jupyter notebook and hosted Colab runtime can run the same Python language while carrying different file and state assumptions. Variables and expressions then establish a line-by-line trace, before strings and lists introduce indices, slices, mutability and aliases.

Functions and decisions compress transformations while making contracts and boundary rules visible. Loops repeat state changes, dictionaries replace positional lookup with named keys, and classes organise state and behaviour into separate instances.

The final chapter uses NumPy, pandas and matplotlib to turn loaded records into a checked grouped table and an appropriate chart.

How assessment shapes preparation

The published plan has three components totalling one hundred per cent. Assignment and in-class discussion carries thirty per cent, the group project carries thirty per cent, and the final paper carries forty per cent.

Within the group project, the teacher's report and presentation mark supplies eighty per cent of the individual component result and a contribution score supplies twenty per cent. The final paper must extend the group research through technical implementation and original analysis. That makes reproducibility, explicit assumptions and a visible individual contribution more valuable than a large amount of unexplained code.

Attendance is a separate published condition: students are required to attend at least 80 percent of scheduled classes. Falling below 80 percent may prevent a student from satisfying the attendance pass condition and may lead to an F; consult the course Moodle page for its course-specific application.

How to study with the guide

For every example, cover the answer and write the next state before running anything.

Record both value and type, draw the boundary positions for slices and branches, and name the progress measure for loops. When code fails, preserve the first error and classify its layer before editing. When code runs, compare it with a hand-computed case and an edge case.

The practice chapter then combines environment, data shape, state and evidence into integrated tasks, while the final page is a submission-day check for the assessed paper.

Worked example · free

Trace a weighted result without flattening the group formula

Q [8 marks]. AskSia-authored practice. Assignment score is 76, teacher group score is 84, contribution score is 90 and final-paper score is 81. Calculate the moderated group result and overall weighted result. Marks shown for this calculation are an AskSia practice allocation, not an official University marking scheme.
The arrow represents evaluation followed by rebinding.The arrow represents evaluation followed by rebinding. Python reads the old value on the right, computes fifteen, and only then changes what the name x refers to.Assignment changes the current bindingbeforex = 10x = x + 5afterx = 15
The arrow represents evaluation followed by rebinding. Python reads the old value on the right, computes fifteen, and only then changes what the name x refers to.
  • 3Calculate the individual group score from the teacher and contribution inputs.
  • 3Apply the three course weights to the correct component values.
  • 2State why the contribution score is not a fourth course component.
The individual group result is 0.80 times 84 plus 0.20 times 90, which equals 85.2. The course result is 0.30 times 76 plus 0.30 times 85.2 plus 0.40 times 81, which equals 80.76. The contribution score sits inside the group-project calculation, so adding it as a separate weighted component would count it twice.
Sia tip — Compute the inner group formula first and label that result before applying the outer course weights.
Glossary

Key terms

Assignment
The operation that evaluates a right-hand expression and binds the name on the left to the resulting value.
Mutability
The capacity of an object such as a list to change while retaining its identity.
Slice
A selected sequence region whose start position is included and whose stop position is excluded.
Return Value
The value a function supplies to its caller, distinct from text the function prints.
Boundary Case
An input at or immediately beside a point where a rule, comparison or valid range changes.
Iteration
One execution of a repeated loop body or the general process of repetition over state or elements.
Dictionary Key
An exact, unique identifier used to locate the associated value in a dictionary.
Instance
A particular object created from a class, carrying its own attribute state.
Inheritance
A subtype relationship through which a child class receives and may specialise a parent interface.
Composition
An ownership or collaboration relationship in which one object contains or uses another object.
DataFrame
A pandas table with labelled rows and columns that can hold different column types.
Groupby
A split-apply-combine operation that partitions rows by keys and calculates a summary for each group.
FAQ

CDT501 FAQ

What does the published assessment consist of?

The course introduction lists Assignment and In-class discussion at thirty per cent, the Group project at thirty per cent and the Final paper at forty per cent. The numeric rows total one hundred per cent. The final item is consistently described as a paper with technical implementation and original analysis, so prepare a reproducible submission rather than an invented timed-exam format.

How is the individual group-project result calculated?

The teacher's group mark for the report and presentation supplies eighty per cent of the individual group-project result, while the contribution score supplies twenty per cent. The contribution element is informed by teammate ratings and reviewed by the instructor. Keep contribution evidence during the project because members of one group can receive different results.

What must the final paper add beyond the group work?

The published guidance says the individual paper must build on the group research foundation while adding technical implementation and original analysis beyond the group's scope. It may include code, data analysis or a technical case study and must distinguish your individual contribution. A narrow reproducible comparison is stronger than a large unexplained application.

How should I trace Python code by hand?

Write the current value and type of each relevant name before a line runs. Evaluate the right side from that state, apply mutation or rebinding, and record any returned value before moving to the next line. Stop at an exception because later lines do not run. For lists and objects, also record whether two names share identity.

Why can a notebook work before restart and then fail?

Notebook cells can be executed in an order different from the order shown on the page. A value created by a later setup cell may remain in memory while an earlier cell appears self-contained. Restart the runtime and run all cells from top to bottom. Move imports, data loading and definitions before their first use so the visible order reproduces the state.

What should I check before trusting a pandas chart?

Inspect the loaded table's shape, labels, types and missing values, then review the filtered or grouped table that supplies the plot. Confirm one summary by hand and match every visual mark to the table. State the unit of observation, aggregation and chart encoding. A polished chart can display a mistaken conversion or grouping rule perfectly.

Does attendance carry a published condition?

The course introduction states that attendance of at least 80 percent of scheduled classes is required. Falling below 80 percent may prevent a student from satisfying the attendance pass condition and may lead to an F under the programme process. Its generic paragraph uses different assessment-access terminology from the Final paper plan, so consult the course Moodle page for its course-specific application.

Chapter questions

Questions students ask in each CDT501 chapter

Why does more storage not always make a program faster?
Storage capacity answers how much persistent data can be kept, while speed depends on the limiting stage of the workload. A task may instead wait on memory, processor work or a network response. Measure loading, computation and saving separately before deciding which resource constrains progress. Chapter 01 · Computer Systems and Execution
How can valid code still solve the wrong problem?
The interpreter checks language rules and performs the operations written. It does not know an omitted weight, unit, threshold or intended output. Expose those premises in variable names, comments and tests, then compare the result with a hand-worked case whose correct answer is independently known. Chapter 02 · Programming Meaning and Environments
Why is x equals x plus one valid in Python?
Python reads it as assignment rather than a timeless mathematical equality. The right side uses the current value bound to x, adds one and produces a result. Only after that evaluation succeeds does the left side update the binding so x refers to the new value. Chapter 03 · Variables, Types and Expressions
Why does a Python slice exclude the stop value?
Slice bounds describe cuts between elements. The start cut is included and the stop cut is excluded, so the number of selected positions often equals stop minus start. This convention aligns slices with sequence lengths and makes adjacent regions meet without duplicating an element. Chapter 04 · Strings, Lists and Mutability
What is the difference between print and return?
Print displays a representation for a person and usually returns None. Return sends a value back to the caller so it can be stored, combined or tested. Keep reusable calculation inside the function and let the caller decide whether and how the returned result should be displayed. Chapter 05 · Functions, Decisions and Boundary Tests
How do I know whether a while loop terminates?
Identify the state used by the condition and show that every path through the body moves it toward making the condition false. If one branch leaves the progress measure unchanged, the loop can stall. Trace the first few passes and the final intended pass before trusting the implementation. Chapter 06 · Loops, Dictionaries and State
Why do two instances keep different values?
Each construction creates a separate object and its instance attributes belong to that object. The objects share method definitions through the class but not ordinary per-instance state. A change through one receiver therefore remains on that receiver unless both objects deliberately reference another shared mutable object. Chapter 07 · Classes, Inheritance and Composition
What is the practical difference between an array and a DataFrame?
A NumPy array offers regular numerical structure and shape-based operations, while a pandas DataFrame adds labelled rows and columns and can hold different column types. Converting between them may lose labels or alter dimensions, so inspect both shape and meaning after each conversion rather than relying on similar printed output. Chapter 08 · NumPy, pandas and Visualisation
Study strategy

How to prepare for the assessments

Begin each study session with a five-minute trace from the previous topic. Write values and types without running the code, then compare your prediction with a fresh execution. For strings, lists and ranges, draw positions and stop-exclusive cuts. For functions, write the contract and test every return path. For branches, test immediately below, at and above each threshold.

For loops, name the progress measure that changes on every pass. For dictionaries, distinguish missing keys from false or empty values. For classes, bind self to one concrete object and follow ownership through every dot. For pandas, preserve intermediate tables and verify a group by hand before plotting. Keep a defect ledger with the layer, evidence, repair and verification for each mistake.

Near the final-paper deadline, select one narrow technical question, rebuild the analysis from original inputs in a fresh runtime and remove any output the prose does not interpret. This routine turns debugging into cumulative knowledge instead of repeated trial and error.

Study CDT501 with AI

Your AI Computer Science tutor for CDT501

Stuck on a hard CDT501 question? Sia is AskSia’s AI Computer Science tutor — ask any CDT501 Computer Systems and Programming Basics question and get a clear, step-by-step explanation grounded in how the course is actually taught and assessed. Read this whole study guide free, then take your hardest questions to Sia.

A+Everything unlocked
Unlocks this Bible + all 9 of your Lingnan University subjects - and 1,000+ Bibles across every Australian university.
Sia - your CDT501 tutor, unlimited, worked the way the exam marks it
The full 44-page Bible + practice bank with worked solutions
Chrome extension - sync your LMS so Sia knows your deadlines
Bilingual EN / Chinese on every Bible and every Sia answer
$0.99 Trial
30-day money-back · cancel in one tap · how it works
CDT501 · Computer Systems and Programming Basics - independent study guide on the AskSia Library. More Lingnan University subjects · Microeconomics across all universities