close menu
Bookswagon-24x7 online bookstore
close menu
My Account
Home > Computing and Information Technology > Computer programming / software engineering > Software Engineering > Software testing and verification > Clean Code: A Handbook of Agile Software Craftsmanship(Robert C. Martin Series)
Clean Code: A Handbook of Agile Software Craftsmanship(Robert C. Martin Series)

Clean Code: A Handbook of Agile Software Craftsmanship(Robert C. Martin Series)

          
5
4
3
2
1

Out of Stock


Premium quality
Premium quality
Bookswagon upholds the quality by delivering untarnished books. Quality, services and satisfaction are everything for us!
Easy Return
Easy return
Not satisfied with this product! Keep it in original condition and packaging to avail easy return policy.
Certified product
Certified product
First impression is the last impression! Address the book’s certification page, ISBN, publisher’s name, copyright page and print quality.
Secure Checkout
Secure checkout
Security at its finest! Login, browse, purchase and pay, every step is safe and secured.
Money back guarantee
Money-back guarantee:
It’s all about customers! For any kind of bad experience with the product, get your actual amount back after returning the product.
On time delivery
On-time delivery
At your doorstep on time! Get this book delivered without any delay.
Notify me when this book is in stock
Add to Wishlist

About the Book

Bestselling author Robert C. Martin brings new life and updated code to his beloved Clean Code book

With Clean Code, Second Edition, Robert C. Martin ("Uncle Bob") reinvigorates the classic guide to software craftsmanship with updated insights, broader scope, and enriched content. This new edition--a comprehensive rewrite of the original bestseller--is poised to transform the way developers approach coding, fostering a deeper commitment to the craft of writing clean, flexible, and maintainable code.

The book is divided into four parts: basic coding practices, design principles and heuristics, high-level architecture, and the ethics of craftsmanship. It challenges readers to critically evaluate code quality and reassess their professional values, ultimately guiding them to produce better software. This edition includes expanded coverage of testing disciplines, design and architecture principles, and multiple programming languages.

  • Design and architecture principles integrated with coding practices
  • Coverage of more languages, including Java, JavaScript, Go, Python, Clojure, C#, and C
  • Case studies for practical exercises in code transformation
  • Techniques for writing good names, functions, objects, and classes
  • Strategies for formatting code for maximum readability
  • Comprehensive error handling and testing practices
  • Productive use of AI tools for coding
  • Soft skills and the ethics of programming
  • SOLID principles of software design
  • Management of dependencies for flexible and reusable code
  • Professional practices and trade-offs in object-oriented design

Clean Code, Second Edition, underscores the importance of evolving software craftsmanship to meet contemporary challenges. Offering a deeper exploration of testing, design, and architecture, alongside universal coding principles applicable across various programming languages, this edition is set to be an indispensable resource for developers, engineers, and project managers. It not only aims to enhance technical skills but also to cultivate a professional ethos that values clean, flexible, and sustainable code.

Register your book for convenient access to downloads, updates, and/or corrections as they become available. See inside book for details.



Table of Contents:

Foreword xix
Introduction xxv
Introduction (from Long Ago) xxix
About the Author xxxi

Chapter 1: Clean Code 1
There Will Be Code 2
Bad Code 3
The Art of Clean Code 5
Putting All This Together 9
We Read More Than We Write 13
The Boy Scout Rule 14

Part I: Code 17

Chapter 2: Clean That Code! 19
The Cleaning Process 30
Conclusion 37
Postscript: Future Bob Playing with Grok3 37
Postscript Conclusion 40

Chapter 3: First Principles 41
Everything Small, Well Named, Organized, and Ordered 42
A More Significant Example 44
A Final Thought 68

Chapter 4: Meaningful Names 71
Use Intention-Revealing Names 72
Final Words 87

Chapter 5: Comments 89
Compensating for Failure 90
Good Comments 92
Bad Comments 97
Conclusion 115

Chapter 6: Formatting 117
The Purpose of Formatting 118
Vertical Formatting 118
Horizontal Formatting 127
Team Rules 132
Uncle Bob's Formatting Rules 133

Chapter 7: Clean Functions 137
Small! 138
Reading Code from Top to Bottom: The Stepdown Rule 140
Switch Statements 142
Clean Functions: A Deeper Look 144
Conclusion 157

Chapter 8: Function Heuristics 159
Function Arguments 159
Command Query Separation 164
Prefer Exceptions to Returning Error Codes 165
DRY: Don't Repeat Yourself 169
Side Effects 177
Structured Programming 181
This Is Too Much to Constantly Keep in Mind 183
Conclusion 184

Chapter 9: The Clean Method 185
Make It Right 186
Example 188
Conclusion 210

Chapter 10: One Thing 211
Extract Method Refactoring 212
What Are Large Functions Anyway? 217
Conclusion 239

Chapter 11: Be Polite 241
The Newspaper Metaphor 243
The Stepdown Rule: Once Again 245
The Abstraction Roller Coaster 246
This Is How We Write, but Not How We Want to Read 246

Chapter 12: Objects and Data Structures 249
What Is an Object? 250
Data Abstraction 251
Data/Object Antisymmetry 252
The Law of Demeter 255
Data Transfer Objects 258
Switch Statements 260
The OO/Procedural Trade-off 264
But What About Performance? 265
Conclusion 265

Chapter 13: Clean Classes 267
Classes and Modules versus Files 267
What Should a Class Contain? 268

Chapter 14: Testing Disciplines 289
Discipline 1: Test-Driven Development (TDD) 291
Discipline 2: Test && Commit || Revert (TCR) 292
Discipline 3: Small Bundles 293
Design 293
Discipline 294
Keeping Tests Clean 299
Tests Enable the -ilities 300

Chapter 15: Clean Tests 303
Domain-Specific Testing Language 307
F.I.R.S.T. 310
Test Design 311
Conclusion 311

Chapter 16: Acceptance Testing 313
The Acceptance Testing Discipline 314
Conclusion 316

Chapter 17: AIs, LLMs, and God Knows What 317
Programming by Prompt 319
Conclusion 328

Part II: Design 329

Chapter 18: Simple Design 331
YAGNI 333
Covered by Tests 333
Maximize Expression 334
Minimize Duplication 337

Chapter 19: The SOLID Principles 341
SRP: The Single Responsibility Principle 343
OCP: The Open–Closed Principle 347
LSP: The Liskov Substitution Principle 351
ISP: The Interface Segregation Principle 354
DIP: The Dependency Inversion Principle 356

Chapter 20: Component Principles 363
Components 364
A Brief History of Components 364
Component Cohesion 368
Component Coupling 373
Conclusion 387

Chapter 21: Continuous Design 389
Continuous Change 390
Continuous Design 391
Sailing on the Four Cs of Continuous Design 392
When Else Do We Design? 420

Chapter 22: Concurrency 423
Why Concurrency? 424
Concurrency Defense Principles 427
2025 Update and Report from the Field 437
Conclusion 442

Part III: Architecture 443

Chapter 23: The Two Values of Software 445
Keeping Options Open 446

Chapter 24: Independence 449
Use Cases 450
Operation 450
Development 451
Deployment 451
Leaving Options Open 451

Chapter 25: Architectural Boundaries 453
What Lines Do You Draw, and When? 454
Plug-in Architecture 456
Case Study: FitNesse 457
Conclusion 459

Chapter 26: Clean Boundaries 461
Third-Party IoT Framework: Lots o' Boundaries 462
UI/Application Boundary 466
Clean Boundaries 474

Chapter 27: The Clean Architecture 475
The Dependency Rule 476
Conclusion 481

Part IV: Craftmanship 483
"A Great Number" 484
Eight Decades 484
The Oath 492

Chapter 28: Harm 495
No Harm to Society 496
Harm to Function 497
No Harm to Structure 499
Soft 500
Tests 501

Chapter 29: No Defect in Behavior or Structure 503
Making It Right 504
Programmers Are Stakeholders 507
Do Your Best 508

Chapter 30: Repeatable Proof 511
Dijkstra 511
Structured Programming 514
Functional Decomposition 516
Test-Driven Development et al. 517

Chapter 31: Small Cycles 519
The History of Source Code Control 519
Continuous Integration 524
Branches versus Toggles 525
Continuous Deployment 527
Continuous Build 528

Chapter 32: Relentless Improvement 529
Test Coverage 529
Mutation Testing 530
Semantic Stability 530
Cleaning 531
Creations 531

Chapter 33: Maintain High Productivity 533
Viscosity 533
Managing Distractions 535
Time Management 538

Chapter 34: Work as a Team 539
Collaborative Programming 539
Open/Virtual Office 540

Chapter 35: Estimate Honestly and Fairly 543
Lies 544
Honesty, Accuracy, Precision 544
Lessons from Me 545
Accuracy and Precision 547
Aggregation 548
Honesty 549
Pressure 550

Chapter 36: Respect for Fellow Programmers 553

Chapter 37: Never Stop Learning 555

Afterword 557

Appendix: The Clean Code Debate 561
Introductions 562
Method Length 563
Method Length Summary 575
Comments 576
Comments Summary 590
John's Rewrite of PrimeGenerator 591
A Tale of Two Programmers 596
Bob's Rewrite of PrimeGenerator2 599
Test-Driven Development 603
TDD Summary 612
Closing Remarks 613

Bibliography 615
Index 619


Best Sellers



Product Details
  • ISBN-13: 9780135398524
  • Publisher: Pearson Education (US)
  • Publisher Imprint: Addison Wesley
  • Language: English
  • Sub Title: A Handbook of Agile Software Craftsmanship
  • ISBN-10: 0135398525
  • Publisher Date: 30 Sep 2025
  • Binding: Digital download
  • Series Title: Robert C. Martin Series


Similar Products

How would you rate your experience shopping for books on Bookswagon?

Add Photo
Add Photo

Customer Reviews

REVIEWS           
Click Here To Be The First to Review this Product
Clean Code: A Handbook of Agile Software Craftsmanship(Robert C. Martin Series)
Pearson Education (US) -
Clean Code: A Handbook of Agile Software Craftsmanship(Robert C. Martin Series)
Writing guidlines
We want to publish your review, so please:
  • keep your review on the product. Review's that defame author's character will be rejected.
  • Keep your review focused on the product.
  • Avoid writing about customer service. contact us instead if you have issue requiring immediate attention.
  • Refrain from mentioning competitors or the specific price you paid for the product.
  • Do not include any personally identifiable information, such as full names.

Clean Code: A Handbook of Agile Software Craftsmanship(Robert C. Martin Series)

Required fields are marked with *

Review Title*
Review
    Add Photo Add up to 6 photos
    Would you recommend this product to a friend?
    Tag this Book
    Read more
    Does your review contain spoilers?
    What type of reader best describes you?
    I agree to the terms & conditions
    You may receive emails regarding this submission. Any emails will include the ability to opt-out of future communications.

    CUSTOMER RATINGS AND REVIEWS AND QUESTIONS AND ANSWERS TERMS OF USE

    These Terms of Use govern your conduct associated with the Customer Ratings and Reviews and/or Questions and Answers service offered by Bookswagon (the "CRR Service").


    By submitting any content to Bookswagon, you guarantee that:
    • You are the sole author and owner of the intellectual property rights in the content;
    • All "moral rights" that you may have in such content have been voluntarily waived by you;
    • All content that you post is accurate;
    • You are at least 13 years old;
    • Use of the content you supply does not violate these Terms of Use and will not cause injury to any person or entity.
    You further agree that you may not submit any content:
    • That is known by you to be false, inaccurate or misleading;
    • That infringes any third party's copyright, patent, trademark, trade secret or other proprietary rights or rights of publicity or privacy;
    • That violates any law, statute, ordinance or regulation (including, but not limited to, those governing, consumer protection, unfair competition, anti-discrimination or false advertising);
    • That is, or may reasonably be considered to be, defamatory, libelous, hateful, racially or religiously biased or offensive, unlawfully threatening or unlawfully harassing to any individual, partnership or corporation;
    • For which you were compensated or granted any consideration by any unapproved third party;
    • That includes any information that references other websites, addresses, email addresses, contact information or phone numbers;
    • That contains any computer viruses, worms or other potentially damaging computer programs or files.
    You agree to indemnify and hold Bookswagon (and its officers, directors, agents, subsidiaries, joint ventures, employees and third-party service providers, including but not limited to Bazaarvoice, Inc.), harmless from all claims, demands, and damages (actual and consequential) of every kind and nature, known and unknown including reasonable attorneys' fees, arising out of a breach of your representations and warranties set forth above, or your violation of any law or the rights of a third party.


    For any content that you submit, you grant Bookswagon a perpetual, irrevocable, royalty-free, transferable right and license to use, copy, modify, delete in its entirety, adapt, publish, translate, create derivative works from and/or sell, transfer, and/or distribute such content and/or incorporate such content into any form, medium or technology throughout the world without compensation to you. Additionally,  Bookswagon may transfer or share any personal information that you submit with its third-party service providers, including but not limited to Bazaarvoice, Inc. in accordance with  Privacy Policy


    All content that you submit may be used at Bookswagon's sole discretion. Bookswagon reserves the right to change, condense, withhold publication, remove or delete any content on Bookswagon's website that Bookswagon deems, in its sole discretion, to violate the content guidelines or any other provision of these Terms of Use.  Bookswagon does not guarantee that you will have any recourse through Bookswagon to edit or delete any content you have submitted. Ratings and written comments are generally posted within two to four business days. However, Bookswagon reserves the right to remove or to refuse to post any submission to the extent authorized by law. You acknowledge that you, not Bookswagon, are responsible for the contents of your submission. None of the content that you submit shall be subject to any obligation of confidence on the part of Bookswagon, its agents, subsidiaries, affiliates, partners or third party service providers (including but not limited to Bazaarvoice, Inc.)and their respective directors, officers and employees.

    Accept

    New Arrivals



    Inspired by your browsing history


    Your review has been submitted!

    You've already reviewed this product!
    ASK VIDYA