Skip to content

Instantly share code, notes, and snippets.

View bansalankit92's full-sized avatar
😎
The cure to boredom is curiosity. There is no cure for curiosity.

Ankit Bansal bansalankit92

😎
The cure to boredom is curiosity. There is no cure for curiosity.
View GitHub Profile
@bansalankit92
bansalankit92 / Clean code.md
Created September 10, 2019 15:06
Lessons learnt from “The Clean Code” — Robert C. Martin

Even bad code can function. But if code isn't clean, it can bring a development organization to its knees.

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.