You are looking ahead. Your place is still task 1: Modules.
A body in a .h, an included .c, a .c not in the target, a forgotten #include, no guard, a variable in a .h, a helper without static.
With modules most mistakes aren't about logic but about what is written in which file.
.h file. While the .h is included in one .c, everything works; with a second one you get multiple definition. A .h holds declarations only.#include "daytime.c". .c files aren't included: they're listed in CMakeLists.txt. Otherwise the functions are defined twice: multiple definition..c file missing from the target. undefined reference to ... – check the add_executable / add_library list. CMake doesn't notice a new file by itself.#include. implicit declaration of function – the compiler doesn't see the declaration. Include the module's .h..c doesn't include its own .h. Then the declaration and the definition can drift apart, and nobody notices until the program starts behaving oddly. The first line of daytime.c is #include "daytime.h".#ifndef guard. Today maybe nothing happens, but in topic 10, when a .h describes a structure, a second inclusion will be an error. Every .h gets a guard, named after the file: DAYTIME_H..h file. int counter; in a header gives the same multiple definition. Data travels as parameters.static. It is visible to the whole program, and another module with the same name causes multiple definition. Whatever isn't in the .h file is static.Each one ticks itself when you do it.
All six done. You know your way around.
It is laid out like CLion: the same panels in the same places. This tour shows each one, and you can reopen it any time with Tour.
Switches the left panel: Lesson plan, Project files, Changes. Click the active icon again to hide the panel.
In CLion: the tool window bar runs down the left edge, too.
This part is not on this task: it appears when a task needs it.
Every task in this lesson. Now marks your place. Clicking a task only lets you look; it never moves your place. Project files and Changes open here too.
In CLion: this spot holds the Project view (the file tree).
This part is not on this task: it appears when a task needs it.
Opens the file for your task by itself. A tab appears for each file the step opens. The breadcrumbs above the code show the folder.
In CLion: the same editor tabs and breadcrumbs.
This part is not on this task: it appears when a task needs it.
Diff shows what changed, like git diff: red is the old code, green the new.
In CLion: the diff view in the Commit window looks the same.
This part is not on this task: it appears when a task needs it.
Terminal for build commands, Database to see your tables. They open by themselves when a task needs them. Drag the top edge to resize.
In CLion: Terminal, and the Database tool window.
This part is not on this task: it appears when a task needs it.
What to do now, right above the code, so you never miss it. Numbered notes in the code explain the important lines. Details shows what you should see and a hint.
In CLion: no equivalent: this is your lecturer's guide.
This part is not on this task: it appears when a task needs it.
Done is the only button that moves you forward. Look back lets you review without losing your place.
This part is not on this task: it appears when a task needs it.
Guided, Focus code or Floating. You can drag the panel edges too. Your layout is remembered for next time.
In CLion: you can also rearrange and hide tool windows.
This part is not on this task: it appears when a task needs it.
Six small missions. Each one ticks itself when you do it, so you know you have found everything.