Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Unindented Code Cannot Possibly Work!

428 views

Published on

Unindented Code Cannot Possibly Work! was presented at the DC Agile Engineering Conference on 12/7/2012 by Ed Buhain (@buhain).

  • Be the first to comment

  • Be the first to like this

Unindented Code Cannot Possibly Work!

  1. 1. Unindented Code Cannot Possibly Work! Ed Buhain December 7, 2012PRIVILEGED AND CONFIDENTIAL. The information contained in this material is privileged and confidential, and is intended only for the use of the individual towhom it is addressed and others who have been specifically authorized to receive it. If you are not the intended recipient, you are hereby notified that anydissemination, distribution or copying of this material is strictly prohibited. If you have received this material in error, please destroy it immediately. #DCAEC12 #DCAEC12
  2. 2. The Ariane 5 $7B development $500M rocket & cargo Software Based on the Ariane 4 #DCAEC12 #DCAEC12
  3. 3. The Ariane 5 Inertial Reference Systems On-Board Computers Boosters & Main Engine #DCAEC12 #DCAEC12
  4. 4. The journey of a thousand milessometimes ends very, very badly.  - Despair, Inc. #DCAEC12 #DCAEC12
  5. 5. About Me NAME: Ed Buhain COMPANY: Excella Consulting EMAIL: ed.buhain@excella.com TWITTER: @buhain BLOG: blog.buhain.com #DCAEC12
  6. 6. Unindented Code Cannot Possibly Work! Ed Buhain December 7, 2012PRIVILEGED AND CONFIDENTIAL. The information contained in this material is privileged and confidential, and is intended only for the use of the individual towhom it is addressed and others who have been specifically authorized to receive it. If you are not the intended recipient, you are hereby notified that anydissemination, distribution or copying of this material is strictly prohibited. If you have received this material in error, please destroy it immediately. #DCAEC12 #DCAEC12
  7. 7. #DCAEC12 #DCAEC12
  8. 8. SOLID Principles S - Single Responsibility O - Open/Closed Principle L - Liskov Substitution I - Interface Segregation D - Dependency Inversion #DCAEC12
  9. 9. #DCAEC12 #DCAEC12
  10. 10. #DCAEC12 #DCAEC12
  11. 11. Unindented code cannot possibly work.  - Jeff Prosise #DCAEC12 #DCAEC12
  12. 12. #DCAEC12 #DCAE
  13. 13. Success is dependent on people,process, technology – in that order.  - Jeff Gallimore #DCAEC12 #DCAEC12
  14. 14. I - Passion #DCAEC12 #DCAEC12
  15. 15. I - Passion #DCAEC12 #DCAEC12
  16. 16. II – Communication Verbal Written #DCAEC12 #DCAEC12
  17. 17. II – Communication #DCAEC12 #DCAEC12
  18. 18. Any fool can write code that acomputer can understand.Good programmers write code thathumans can understand.  - Martin Fowler #DCAEC12 #DCAEC12
  19. 19. Does This Code Work? If (productNames.Count > 0) Then lblProductName1.Text = productNames(0) lblProductName1.Visible = True End If If (productNames.Count > 1) Then lblProductName2.Text = productNames(1) lblProductName2.Visible = True End If . . . If (productNames.Count > 98) Then lblProductName99.Text = productNames(98) lblProductName99.Visible = True End If #DCAEC12
  20. 20. Does This Code Work? SELECT a.CustomerName AS a, b.Address1 AS b, b.City AS c, b.PostalCode AS d, c.OrderNumber AS e FROM Customers a INNER JOIN Addresses b ON b.AddressId = a.AddressId INNER JOIN Orders c ON c.CustomerId = a.CustomerId WHERE c.IsProcessed = 0 #DCAEC12
  21. 21. Does This Code Work? // increment j i++; #DCAEC12
  22. 22. Does This Code Work?string iCustnm;iCustnm = "644";if (Cust.Has_Orders(iCustnm))processOrders(iCustnm);else wiatforOrdersw(iCustnm);Display_Customer_Orders(iCustnm.ToString()); #DCAEC12
  23. 23. III – Tools & Techniques #DCAEC12
  24. 24. Skynet became self-aware.  - The Terminator #DCAEC12 #DCAEC12
  25. 25. Know Your Tools! // Doug H. - 12/11/2010 - Bug 2733 // Rachel G. - 11/17/2010 - Bug 2544 // Doug H. - 11/11/2010 - Bug 2211 // Doug H. - 10/29/2010 - Bug 2211 // Howard W. - 8/6/2010 - Bug 2099 // Norm P. - 4/11/2010 - Bug 1556 // Doug H. - 1/14/2010 - Bug 1444 ProcessPayment(payment); #DCAEC12
  26. 26. Know Your Tools!/* * * Edited by Doug H. * Thursday 3:45 p.m. * Outside Temperature 38°F * I live at 65 Main Street. * I wish I was on vacation. I have 6 days of vacation left. * */ #DCAEC12
  27. 27. CuStOmErADDRESSid #DCAEC12 #DCAEC12
  28. 28. III – Tools & Techniques Know Your Tools Think About Presentation #DCAEC12 #DCAEC12
  29. 29. #DCAEC12
  30. 30. #DCAEC12
  31. 31. You’re Surrounded! Think of something you think is poorly designed. Share with your group. #DCAEC12
  32. 32. We’re Surrounded! Pick a group representative. Share with the whole room. #DCAEC12
  33. 33. #DCAEC12
  34. 34. #DCAEC12#DCAEC12
  35. 35. Attractive things work better.  - Donald A. Norman #DCAEC12 #DCAEC12
  36. 36. Know Your Patterns #DCAEC12
  37. 37. Know Your Patterns #DCAEC12
  38. 38. Know Your Patterns #DCAEC12
  39. 39. Know Your Patterns #DCAEC12
  40. 40. Know Your Patterns #DCAEC12
  41. 41. Know Your Patterns #DCAEC12
  42. 42. Know Your Patterns You are confirmed on United Airlines flight 2049, departing from Washington-Dulles Airport at 10:00 a.m. on Friday, December 7, 2012 and arriving at Seattle-Tacoma International Airport at 3:00 p.m. United Flight 2049 Washington-Dulles to Seattle- Tacoma Departs: Fri 12/7 10:00 AM #DCAEC12
  43. 43. Putting It All Together… #DCAEC12
  44. 44. Reading List #DCAEC12
  45. 45. Reading List #DCAEC12
  46. 46. What do you think about when youhear the term legacy code?… the sort of code that you just wishwould die.  - Michael Feathers #DCAEC12 #DCAEC12
  47. 47. About Me NAME: Ed Buhain COMPANY: Excella Consulting EMAIL: ed.buhain@excella.com TWITTER: @buhain BLOG: blog.buhain.com #DCAEC12

×