Coding best practices: Difference between revisions

Content deleted Content added
Loloolk (talk | contribs)
Added context for programming examples in "Keep the Code Simple". Revised language/links.
top: Replacing inaccessible book link with a citation that includes an OCLC that links to a Worldcat record that lists ebooks. They may be behind a paywall, but I think this is better. Removed comment. Please do not insert comments into the Wikitext that would be better placed on the talk page.
Line 4:
}}
 
'''Coding best practices''' or '''programming best practices''' are a set of informal rules (''[[best practice]]s'') that many [[software developer]]s in [[computer programming]] follow to improve [[software quality]].<ref name="McConnell 2004 p. ">{{cite book |titlelast=CodeMcConnell Complete|urlfirst=https://archive.org/details/codecomplete0000mccoSteve |urlauthor-accesslink=registrationSteve McConnell |editiontitle=SecondCode Complete |lastpublisher=McConnellMicrosoft Press |firstpublication-place=SteveRedmond, Wash. |year=2004|publisher=Microsoft Press|isbn=978-0-7356-19679125-04 |oclc=61315783 |page={{page needed|date=November 2023}}}}</ref><!-- I can't access this source. --> Many computer programs remain in use for long periods of time,<ref>{{cite book|title=Software Engineering|edition=Seventh|last=Sommerville|first=Ian|year=2004|publisher=Pearson|isbn=0-321-21026-3|page=38}}</ref> so any rules need to facilitate both initial development and subsequent maintenance and enhancement of [[source code]] by people other than the original authors.
 
In the [[ninety–ninety rule]], Tom Cargill is credited with an explanation as to why programming projects often run late: <!-- these do add to 180%, and are meant to (=late project). See linked Ninety-ninety rule --> "The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time."<ref name="Bentley1985">{{cite journal|last=Bentley|first=Jon|year=1985|title=Programming pearls: Bumper-Sticker Computer Science|journal=Communications of the ACM|volume=28|issue=9|pages=896–901|issn=0001-0782|doi=10.1145/4284.315122|s2cid=5832776|doi-access=free}}</ref> Any guidance which can redress this lack of foresight is worth considering.