We may earn an affiliate commission when you visit our partners.
Course image
Geert Jan Bex, Ingrid Barcena, Mag Selwa, and Yulia Kallistratova

Most FutureLearn courses run multiple times. Every run of a course has a set start date but you can join it and work through it after it starts. Find out more This is an intermediate level course aimed at people with some programming experience. Although examples will be given in C and Fortran, the principles (and most of the tools) are transferable to other programming languages. You can use the hashtag #FLdebugging to talk about this course on social media.

Topics Covered

Read more

Most FutureLearn courses run multiple times. Every run of a course has a set start date but you can join it and work through it after it starts. Find out more This is an intermediate level course aimed at people with some programming experience. Although examples will be given in C and Fortran, the principles (and most of the tools) are transferable to other programming languages. You can use the hashtag #FLdebugging to talk about this course on social media.

Topics Covered

  • Defensive programming: the use of good coding style, documentation strategies and good code testing
  • Preventing bugs: how to use compiler flags and static code checkers to identify bugs in an early stage
  • Finding bugs: debugging concepts and technics
  • Using the debugging tools GDB and Valgrind to fix serial programs
  • Debugging parallel code: using Intel Inspector and ITAC

Save this course

Create your own learning path. Save this course to your list so you can find it easily later.
Save

Reviews summary

Practical debugging and defensive coding

According to students, this course is a highly practical and insightful guide to defensive programming and debugging. Learners particularly praise its coverage of essential debugging tools like GDB and Valgrind, and the invaluable strategies for preventing bugs proactively. While many find the content exceptionally useful for writing robust code and appreciate the logical course structure, some indicate that the explanations for certain tools can be a bit rushed, suggesting a need for more hands-on labs or interactive exercises. It is widely recognized as an intermediate-level course, benefiting greatly from prior programming experience, especially in C.
Best suited for those with existing programming experience.
"It truly is an intermediate course, so having some C/Fortran background helps immensely."
"I struggled to keep up without prior extensive knowledge of C."
"This course was a bit challenging at times if you're not deeply familiar with C programming."
Covers essential debugging tools like GDB and Valgrind effectively.
"The modules on Valgrind and GDB were particularly well-explained, making complex debugging techniques accessible."
"I particularly appreciated the detailed coverage of GDB."
"I found the examples for GDB and Valgrind helpful and directly applicable to my projects."
Teaches highly practical strategies for robust coding and bug prevention.
"This course was incredibly insightful and practical. The focus on real-world application is excellent."
"Absolutely essential for anyone serious about writing robust code. The section on static code checkers and compiler flags helped me catch so many potential bugs..."
"The insights into preventing bugs proactively are invaluable. I particularly appreciated the detailed coverage of GDB."
"This course really improved my coding habits. The defensive programming strategies taught are gold."
Some found the pacing inconsistent and engagement varied.
"While the topics are important, I felt the course was quite dry and the pacing was inconsistent. Some parts moved too fast, others too slow."
"The course has good theoretical content, but I found some of the explanations for tools like GDB and Valgrind a bit rushed."
"My only minor critique is that the audio quality in some lectures wasn't great, but the slides were clear."
Some learners desire more hands-on exercises for tools.
"I found some of the explanations for tools like GDB and Valgrind a bit rushed. I had to look up external resources... Perhaps more hands-on labs would improve this."
"The practical application of the tools was not as strong as I hoped. I struggled with some of the assignments without more guided examples."
"I agree with others that some parts could benefit from more interactive exercises or clearer demonstrations."

Career center

Learners who complete Defensive Programming and Debugging will develop knowledge and skills that may be useful to these careers:

Reading list

We've selected 50 books that we think will supplement your learning. Use these to develop background knowledge, enrich your coursework, and gain a deeper understanding of the topics covered in Defensive Programming and Debugging.
Classic in the field of TDD and provides a comprehensive overview of the topic. It is written by Kent Beck, who is one of the pioneers of TDD.
Provides a comprehensive overview of static code analysis techniques, their applications, and their benefits. It is written by a leading researcher in the field and covers both the theoretical foundations and practical aspects of static code analysis.
Provides a comprehensive overview of code optimization techniques, covering both theoretical foundations and practical implementation. Co-authored by distinguished computer scientists and pioneers in the field, this foundational book in the study of code optimization.
This classic book is the definitive guide to the C programming language. It was written by the language's creators and provides a comprehensive overview of the language's syntax, semantics, and standard library.
Widely known as the 'Dragon Book,' this foundational text covering the fundamental principles and techniques of compiler design, including a strong introduction to optimization. It is an excellent starting point for gaining a broad understanding and is commonly used as a textbook in undergraduate and graduate programs. While not the most recent, its core concepts remain highly relevant.
Great way to learn how to write better C programs. It covers a wide range of topics, from the basics of the language to more advanced concepts such as debugging and testing.
Great way to learn how to write more efficient and effective C programs. It covers a wide range of topics, from the basics of the language to more advanced concepts such as optimization and concurrency.
Provides a foundational understanding of debugging principles applicable to both software and hardware. It outlines nine fundamental rules and offers practical strategies for identifying and resolving bugs. This is an excellent starting point for anyone new to debugging, providing a solid framework before diving into language-specific techniques. It is widely recommended for its accessible approach and timeless advice.
Provides a comprehensive and practical approach to building a modern compiler, with a significant focus on optimization techniques. It is highly regarded for its detailed explanations of algorithms and their implementation, making it suitable for both students and professionals. The latest edition incorporates recent developments in the field.
Drawing on extensive experience, this book presents a comprehensive collection of 66 specific and actionable debugging techniques. It covers a wide range of scenarios and provides practical advice for tackling complex software and system issues. is highly valuable for experienced programmers looking to expand their debugging toolkit and improve their efficiency in finding and fixing errors. It useful reference for various debugging challenges.
Offers a systematic and theoretical approach to debugging, moving beyond ad-hoc methods. It covers techniques for reproducing failures, isolating causes, and understanding the debugging process from a scientific perspective. While it delves into theoretical concepts, it also provides practical examples and insights into automated debugging tools. This book is valuable for those who want to deepen their understanding of the underlying principles of debugging.
Explores advanced techniques for compiler optimization, with a focus on dependence analysis and parallelization. Understanding compiler optimizations can provide insights into how code is transformed and optimized at the compiler level.
Delves into advanced topics in compiler design and implementation, with a strong emphasis on optimization. It valuable resource for those seeking to deepen their understanding of complex optimization techniques and is often referenced by researchers and practitioners in the field.
This classical textbook provides an accessible introduction to parallel computing. It covers fundamental concepts, programming models, and algorithms, making it ideal for students and professionals alike. (fit_score: 90, difficulty_score: 60)
Offers practical strategies and techniques for finding, repairing, and preventing bugs, with a focus on enterprise software development. It provides a hands-on approach to improving your debugging skills and tackling common issues encountered in real-world projects. This book good resource for developers seeking to enhance their day-to-day debugging practices and reduce the number of defects in their code.
Focuses on advanced debugging techniques for .NET applications using native debugging tools like WinDBG. It delves into the internals of the .NET CLR and provides in-depth knowledge for tackling complex .NET bugs. This is an essential resource for experienced .NET developers and those involved in troubleshooting production issues.
Focuses on verification and debugging approaches specifically for embedded software with hardware dependencies. It covers the entire flow from design to debugging and explores various verification techniques. This specialized book for those working at the intersection of software and hardware in embedded systems.
Aimed at programmers with object-oriented experience, this book teaches to see the benefits of unit testing for the design and development of object-oriented applications.
Specifically addresses the back-end of the compiler, focusing on code generation and machine-level optimizations. It is valuable for understanding how optimizations are applied to generate efficient code for target processors.
This book, part of the Modern Compiler Implementation series, focuses on compiler construction using the C programming language. It provides a hands-on approach to understanding compiler principles and optimizations, suitable for those with a C programming background.
Focuses on practical debugging using popular tools like GDB, DDD, and Eclipse, commonly used in Linux/Unix environments. It provides hands-on guidance for using these debuggers effectively, covering topics such as inspecting variables, understanding memory issues, and debugging different programming paradigms. This is particularly useful for students and professionals working with C, C++, Java, Perl, or Python on these platforms. It serves as a valuable reference for tool-specific debugging.
Part of a series (including Java and C versions), this book offers a practical approach to compiler implementation using the ML programming language. It covers fundamental concepts and advanced topics, including optimization, and is well-suited for students and those who want to understand compiler construction by building one.
Explores advanced debugging techniques, including those based on program analysis, visualization, and automated approaches. It delves into more complex debugging scenarios and provides insights into cutting-edge methods. This book is suitable for experienced developers and researchers interested in the theoretical underpinnings and advanced practices of debugging.
Classic in the field of software engineering and covers a wide range of topics, including static code analysis. It provides practical advice on how to write high-quality code and avoid common pitfalls.
This handbook aims to provide programmers with essential knowledge and techniques for effective debugging. It covers a range of topics and offers practical advice for approaching debugging challenges systematically. It serves as a good general reference for developers looking to improve their debugging skills.
Great introduction to the C programming language for beginners. It covers the basics of the language in a clear and concise style.
Great introduction to the C programming language for absolute beginners. It covers the basics of the language in a clear and concise style.
Takes a unique approach by guiding the reader through the process of building a debugger from scratch for x64 Linux systems using C++. This provides a deep understanding of how debuggers work internally, which can significantly enhance debugging skills regardless of the tools used. This is an advanced book suitable for those who want a thorough understanding of debugging at a low level.
Specifically addresses the challenges of debugging and optimizing legacy code. It provides strategies and techniques for working with older, often poorly documented, codebases to identify and fix bugs and improve performance. This valuable resource for developers dealing with the realities of maintaining existing software systems.
This comprehensive textbook covers a wide range of parallel programming techniques using various platforms, including networked workstations and parallel computers. It emphasizes practical applications and provides hands-on exercises. (fit_score: 75, difficulty_score: 80)
Explores debugging from a multidisciplinary perspective, drawing on various fields to inform debugging strategies. It encourages a thoughtful and systematic approach to problem-solving in the context of finding and fixing bugs. This book is for those who want to deepen their understanding of the cognitive processes involved in effective debugging.
Provides a survey of traditional aspects of the software testing domain, such as test types, test planning, and test management plus some information on TDD.
XUnit Test Patterns serves as a guide to improve and refactor test code. The patterns help software developers and testers increase the maintainability and readability of their test code, as well as its effectiveness.
Covers performance optimization techniques for Python code. It provides practical guidance on identifying and eliminating performance bottlenecks, as well as optimizing for specific hardware and software environments.
Presents compiler design using an incremental approach, building up a working compiler step by step. It covers various compilation stages and introduces optimization concepts along the way, making it a practical choice for learning.
Provides an in-depth explanation of modern Fortran, a language that is particularly suitable for high-performance scientific computing. Understanding Fortran's features and capabilities can enable developers to write highly optimized code for scientific applications.
This widely acclaimed book for software developers includes valuable insights into the debugging process as part of a broader approach to building robust and maintainable software. It emphasizes practical advice and best practices that indirectly contribute to reducing bugs and improving debugging efficiency. While not solely focused on debugging, its principles are highly relevant and make it a must-read for any programmer.
Provides a collection of best practices and guidelines for writing effective Java code. Following these guidelines can help improve code quality, performance, and maintainability.
An earlier classic by two of the authors of the 'Dragon Book,' this text provides foundational knowledge in compiler design. While predating many modern optimization techniques, it is valuable for understanding the historical context and core principles. It is often referred to as the 'Green Dragon Book'.
This textbook offers an introduction to compiler design suitable for undergraduates. While it may not delve into the deepest levels of optimization, it provides a solid foundation in the overall compilation process, including basic optimization concepts.
This influential book focuses on writing clean, readable, and maintainable code. While not a debugging book per se, writing clean code significantly reduces the likelihood of introducing bugs and makes the debugging process much easier when they do occur. The principles outlined in this book are fundamental for preventing many common errors.
While primarily focused on interpreters, this book provides a very practical and hands-on introduction to the concepts of language implementation, including some foundational ideas relevant to compilers and optimization. It's an excellent starting point for those new to language processing.
This free online textbook that provides an introduction to compiler construction. It covers the essential steps of building a compiler and good resource for beginners, including some discussion of basic optimizations.
This textbook provides a comprehensive overview of parallel computer architecture, covering both hardware and software aspects. It discusses different parallel architectures, programming models, and performance optimization techniques. (fit_score: 65, difficulty_score: 85)
This introductory textbook covers fundamental concepts of parallel programming, including concurrency, synchronization, and load balancing. It uses Java as the programming language and provides hands-on exercises and case studies. (fit_score: 60, difficulty_score: 55)

Share

Help others find this course page by sharing it with your friends and followers:

Similar courses

Here are nine courses similar to Defensive Programming and Debugging.
Computational Thinking for K-12 Educators: Nested If...
Most relevant
Interactivity with JavaScript
Most relevant
Python Scripting Case Study - Creating a Console...
Most relevant
Mendix Advanced Workflows and Integrations
Most relevant
Java for Beginners: Hands-On Course with Capstone Project
Most relevant
Optimizing Your Workflow with GitHub Copilot and VS Code
Most relevant
React Native: Developing Android and iOS Apps
Most relevant
Learning Unity and C# for Complete Beginners
Most relevant
Learn Go for Beginners Crash Course (Golang)
Most relevant

Futurelearn Buyer Protection & Guarantee

Verified partner policies & purchase protections

UK & International University Partner
Free Trial & Audit

Free Access on Short Courses

Free access option on most short courses for the duration of the course plus 14 days; free trial available on select subscriptions and tracks.

Return & Refund Policy

14-Day Cooling-Off Refund Window

14-day statutory cooling-off refund window from the date of purchase for course upgrades, Unlimited subscriptions, and ExpertTracks, provided no tests have been attempted and no certificates have been downloaded. Renewals are non-refundable.

Buyer Protections

Verified Academic & Industry Partner

Accredited university microcredentials and certificates from top institutions (British Council, leading UK and global universities), with secure payment safeguards.

Key Purchase Protections
Free access track on many short courses
14-day cooling-off refund window on initial purchases
Refund eligible if no tests completed and no certificate issued
Accredited certifications from top UK & global universities
OpenCourser Verified Partner Policy details last reviewed: 2026-10-22
Our mission

OpenCourser helps millions of learners each year. People visit us to learn workspace skills, ace their exams, and nurture their curiosity.

Our extensive catalog contains over 50,000 courses and twice as many books. Browse by search, by topic, or even by career interests. We'll match you to the right resources quickly.

Find this site helpful? Tell a friend about us.

Affiliate disclosure

We're supported by our community of learners. When you purchase or subscribe to courses and programs or purchase books, we may earn a commission from our partners.

Your purchases help us maintain our catalog and keep our servers humming without ads.

Thank you for supporting OpenCourser.

© 2016 - 2025 OpenCourser