Abbreviations.com Convert.net Definitions.net Lyrics.net Phrases.net Quotes.net References.net Rhymes.net Synonyms.net USZip.com  Bookmark and Share
 
Definitions.net
Search for Dictionary Definitions:  
Browse Alphabetically:
 A   B   C   D   E   F   G   H   I   J   K   L   M   N   O   P   Q   R   S   T   U   V   W   X   Y   Z   # 
 random definition 

 Definitions of fencepost error  

Translate fencepost error to



Definitions of 'fencepost error' The New Hacker's Dictionary 

1.  fencepost error
1. [common] A problem with the discrete equivalent of a boundary condition, often exhibited in programs by iterative loops. From the following problem: “If you build a fence 100 feet long with posts 10 feet apart, how many posts do you need?” (Either 9 or 11 is a better answer than the obvious 10.) For example, suppose you have a long list or array of items, and want to process items m through n; how many items are there? The obvious answer is n - m, but that is off by one; the right answer is n - m + 1. A program that used the ‘obvious’ formula would have a fencepost error in it. See also zeroth and off-by-one error, and note that not all off-by-one errors are fencepost errors. The game of Musical Chairs involves a catastrophic off-by-one error where N people try to sit in N - 1 chairs, but it's not a fencepost error. Fencepost errors come from counting things rather than the spaces between them, or vice versa, or by neglecting to consider whether one should count one or both ends of a row.

2. [rare] An error induced by unexpected regularities in input values, which can (for instance) completely thwart a theoretically efficient binary tree or hash table implementation. (The error here involves the difference between expected and worst case behaviors of an algorithm.)



'fencepost error' - Nearby Entries  

feeping creature  feeping creaturism  feetch feetch  fencepost error  fiber seeking backhoe  fidonet  field circus  



Citation: Add this definition to your bibliography   MLA  Chicago  APA 
"fencepost error." Definitions.net. STANDS4 LLC, 2012. 31 May. 2012. http://www.definitions.net/definition/fencepost error


Alternative search options for 'fencepost error'   
Search for Synonyms for 'fencepost error'
Quotes containing the term 'fencepost error'
Search for Phrases containing the term 'fencepost error'
Search for Abbreviations containing the term 'fencepost error'
Search for 'fencepost error' on Search fencepost error on Amazon.com! & Search fencepost error on Google.com!
What rhymes with 'fencepost error'?
NEW:Search for Song lyrics containing the word 'fencepost error'


Definitions.net |  Login |  Add New Abbreviation |  Your List |  Tools |  Become an Editor |  Tell a Friend |  Awards |  Testimonials |  Press |  News |  Forum new! |  APIs |  About
Copyright ©2001-2011 STANDS4 LLC. All rights reserved.  Terms of Use  |  Privacy Policy  |  Advertise  |  Contact Us  Follow us on Facebook! Follow us on Twitter!