All field notes Start reading

What learning C at 42 Lausanne taught me

Learning C at 42 Lausanne made memory, ownership, and failure handling concrete—and showed me the value of explaining code to other people.

An exposed precision assembly reveals connected inner components, representing low-level programming.
Editorial illustration.

Learning C makes the costs hidden by higher-level abstractions harder to ignore. A string needs storage and a terminator. A file descriptor has a lifetime. A successful allocation needs a corresponding ownership decision, and a failed one needs a path the program can handle.

My experience at 42 Lausanne helped me connect those details to the way software behaves. The value was technical, but it also came from learning with other people: explaining an approach, examining another solution, and discovering where an assumption stopped holding.

Introduction to C and C++

C developed alongside Unix at Bell Labs. Dennis Ritchie’s account of the language’s development describes its early-1970s origins as a system implementation language. Its small set of core mechanisms gives programmers substantial control over memory layout and interaction with the operating system.

C++ grew from work on C with Classes and supports several programming styles, including procedural, object-oriented, and generic programming. Bjarne Stroustrup’s explanation is a useful corrective to treating it as simply “C plus objects.” Modern C++ also provides resource-management abstractions that can make explicit ownership easier to express.

When to Use C and C++

These languages are relevant when an application needs a particular system interface, predictable control over resources, compatibility with an existing codebase, or carefully measured performance. Embedded software, operating-system components, graphics engines, and infrastructure are familiar examples.

They also require discipline. Direct control does not automatically produce speed or correctness. Bounds errors, invalid lifetimes, and undefined behavior can undermine both. A language choice should account for the team’s expertise, the system’s safety requirements, and the cost of maintaining it.

For a web service, for example, the demanding computation may belong in a native library while the surrounding application uses a higher-level language. There is no requirement to choose one level of abstraction for every part of a product.

Where C and C++ Shine

The strongest reason to learn them is the ability to reason about what a program asks the machine to do. That understanding remains useful even when the final application is written elsewhere.

Consider a function that returns a pointer. Who allocated the memory? How long is it valid? Who must release it? What happens on an error halfway through the operation? A clear interface answers those questions instead of leaving each caller to guess.

The same reasoning applies to open files, network connections, and locks. Performance and reliability often improve together when the lifetime and ownership of resources are explicit.

Experience at 42 Lausanne

The Piscine immersed me in C and shell exercises over an intensive month. Solving problems and evaluating other students’ work made the learning active: an explanation had to survive questions, and a solution had to work beyond the first successful input.

That peer-learning environment helped me develop the habits behind the syntax. I had to break a problem into smaller pieces, read documentation, and make my reasoning understandable to someone else. Project-based work also made gaps visible quickly; knowing a concept in the abstract was different from using it in a program.

The experience reinforced the value of learning by doing and learning through review. Those habits transfer directly to engineering teams, where a design is stronger when colleagues can inspect its assumptions and failure paths.

Conclusion

C and C++ are useful tools for understanding how software consumes and manages resources. My time at 42 Lausanne made that understanding more concrete. The lasting lesson is to be able to explain what the code owns, what it assumes, and what it does when those assumptions fail.

Share