
Grade 12 · 18 weeks
Computer Science
Build and test a Lantern Festival scorer, model data, and design a program that people can use without giving up unnecessary personal information.
Start Week 2Term 1 · Algorithms, programs and testing
Bits, characters and color
A sequence of bits has meaning under an encoding. The same bit pattern can represent a number, a text-related value or part of a color. A hexadecimal digit represents four bits.
Read-aloud is not available in this browser. You can still read this text on screen.
Computing lab
Convert 00001111 to decimal and hexadecimal, then compare the representations of the character A and the red channel in #FF2200. Describe what changes when you change the interpretation without changing the bits.
Keep for review. A conversion table with the encoding or interpretation labeled for each row.
JavaScript starter code
Save this example as a .js file and run it in Node.js or an editor your educator approves.
console.log(Number.parseInt('00001111', 2));
console.log((15).toString(16));
console.log(new TextEncoder().encode('A')[0]);
console.log(Number.parseInt('FF', 16));Plan the week
- Read the lesson and explain its main idea in your own words.
- State the system or program’s goal and sketch its inputs, rules and output.
- Complete the investigation and keep the evidence listed above.
- Test or trace a second case and record any change it suggests.
- Answer the week’s check, then explain your reasoning using your evidence.

