Brainlag
  1. C
  2. Core
18/38 lessons

Checkpoint: text and structs

Checkpoint35 min3 problemsPremium

Three problems on your own: turn messy lines into an array of structs, find out why a command is never recognised, and predict what sscanf fills in.

The skill
Show you can turn lines of text into checked, parsed structs without step-by-step help.
You make
A leaderboard built from raw input lines, a command loop fix and a trace of what sscanf fills in.

Premium lesson

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

Builds on 17 Structs and padding. Free to try: C Foundations and the playground.

Step 1 of 4
exercise_1.c

You've reached the good stuff.

3 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