Brainlag
  1. C
  2. Bits and a tiny machine
38/38 lessons

Checkpoint: bits and a tiny machine

Checkpoint50 min5 problemsPremium

Five problems on your own: blend packed colours, parse permissions, find a broken top flag, predict flag changes and make a virtual machine refuse bad programs.

The skill
Show that you can pack, unpack and test bits and keep a small virtual machine safe without step-by-step help.
You make
A colour blender, a permission parser, a fixed flag check and a virtual machine that reports bad programs.

Premium lesson

£7.99 a month or £59 a year. Cancel any time.

Builds on 37 A tiny stack machine. Free to try: C Foundations and the playground.

Step 1 of 6
exercise_1.c

You've reached the good stuff.

5 exercises in this lesson, checked as you type. Premium opens every lesson after Foundations, in all four courses.

C, 32-bit: int and pointers are 4 bytes