Successfully reported this slideshow.

Code Excellence for the Average Programmer

8

Share

Upcoming SlideShare
Clean code, Feb 2012
Clean code, Feb 2012
Loading in …3
×
1 of 62
1 of 62

Code Excellence for the Average Programmer

8

Share

Download to read offline

Are you happy at work? Are you proud of the code you are working with? This session seeks to inspire engineers to adopt a sense of pride of ownership toward code they are working with. The long term benefits of working with code that continually grows better and easier to work on are almost too numerous it list. Take a ride with Llewellyn & Woody as we explore the road to happy code. One of the main tenants of agile is the ability to respond to change. This talk will focus on how to get malleability back into your existing code through the eXtreme programming practice of Refactoring.

Are you happy at work? Are you proud of the code you are working with? This session seeks to inspire engineers to adopt a sense of pride of ownership toward code they are working with. The long term benefits of working with code that continually grows better and easier to work on are almost too numerous it list. Take a ride with Llewellyn & Woody as we explore the road to happy code. One of the main tenants of agile is the ability to respond to change. This talk will focus on how to get malleability back into your existing code through the eXtreme programming practice of Refactoring.

More Related Content

Related Books

Free with a 14 day trial from Scribd

See all

Code Excellence for the Average Programmer

  1. 1. Code Excellence for the Average Programmer By Llewellyn Falco & Woody Zuill
  2. 2. How many are working with legacy code? 2
  3. 3. VS
  4. 4. Goal: Simple Techniques for Code Excellence
  5. 5. Project: Charting Project 6
  6. 6. the golden rule Leave things BETTER than you found them
  7. 7. Never be more than 2 minutes away from checking in and going home
  8. 8. Arm Yourself
  9. 9. Arm Yourself Tests
  10. 10. Arm Yourself Tests Tools
  11. 11. Arm Yourself Tests Tools Patterns
  12. 12. What makes code hard to work with?
  13. 13. Remove the 3 C’s...
  14. 14. Remove the 3 C’s... Clutter
  15. 15. Remove the 3 C’s... Clutter Complexity
  16. 16. Remove the 3 C’s... Clutter Complexity Cleverness
  17. 17. Removing Clutter Definition : Clutter is anything in your code that does not add value.
  18. 18. Removing Clutter Definition : Clutter is anything in your code that does not add value. Format your code
  19. 19. Removing Clutter Definition : Clutter is anything in your code that does not add value. Format your code Delete comments
  20. 20. Removing Clutter Definition : Clutter is anything in your code that does not add value. Format your code Delete comments Delete dead code
  21. 21. Removing Clutter Definition : Clutter is anything in your code that does not add value. Format your code Delete comments Delete dead code Delete unnecessary code
  22. 22. Removing Complexity
  23. 23. Removing Complexity Bad Names
  24. 24. Removing Complexity Bad Names Long Methods
  25. 25. Removing Complexity Bad Names Long Methods Deep Conditionals (if/for/while/switch)
  26. 26. Removing Complexity Bad Names Long Methods Deep Conditionals (if/for/while/switch) Magic Numbers
  27. 27. Removing Complexity Bad Names Long Methods Deep Conditionals (if/for/while/switch) Magic Numbers Improper Variable Scoping
  28. 28. Removing Complexity Bad Names Long Methods Deep Conditionals (if/for/while/switch) Magic Numbers Improper Variable Scoping Missing Encapsulation
  29. 29. Removing Complexity Bad Names Long Methods Deep Conditionals (if/for/while/switch) Magic Numbers Improper Variable Scoping Missing Encapsulation Obscure Code Blocks
  30. 30. Removing Cleverness “If it’s simple and elegant, you wouldn’t refer to it as ‘clever’”
  31. 31. Removing Cleverness “If it’s simple and elegant, you wouldn’t refer to it as ‘clever’” Cryptic Code
  32. 32. Removing Cleverness “If it’s simple and elegant, you wouldn’t refer to it as ‘clever’” Cryptic Code Abbreviated Code
  33. 33. Removing Cleverness “If it’s simple and elegant, you wouldn’t refer to it as ‘clever’” Cryptic Code Abbreviated Code Hijacking a Method(changing its intent for your own purposes)
  34. 34. ... and the 3 D’s
  35. 35. ... and the 3 D’s Duplication
  36. 36. ... and the 3 D’s Duplication Duplication
  37. 37. ... and the 3 D’s Duplication Duplication Duplication
  38. 38. Our code base is just a big mess, and no one is happy working in it.
  39. 39. Next Steps :-) 1-2
  40. 40. Next Steps Spring Cleaning Week - Start each task with 25 minutes of cleaning with a co-worker. :-) 1-2
  41. 41. Next Steps 2-2
  42. 42. Next Steps Books 2-2
  43. 43. Next Steps Books ‘Clean Code’ by Robert Martin 2-2
  44. 44. Next Steps Books ‘Clean Code’ by Robert Martin ‘Working Effectively with Legacy Code’ by Michael Feathers 2-2
  45. 45. What we offer
  46. 46. What we offer • Day Classes on site •Single day class to educate & train employees on a single aspect of agile
  47. 47. What we offer • Day Classes on site •Single day class to educate & train employees on a single aspect of agile • On site Coaching •Minimum 2 weeks working on site with employees on their stuff. •Training/Mentoring •Setup of framework •Source Control •Automated Builds •Continuous integration •Work environment
  48. 48. www.ApprovalTests.com check here for more information about how we actually tested the code
  49. 49. Contact Woody Zuill wzuill@yahoo.com Llewellyn Falco info@spunlabs.com
  50. 50. Goal: Simple Techniques for Code Excellence

Editor's Notes

×