• Contact Us
  • About
  • Policy
  • Job Opportunities
  • Benaija Lectures
  • News
  • Comic Videos
  • Christian Articles
Benaija | The Naija News Talker
  • Home
  • Health Tips
  • Gadgets
    • Smart Phones
    • Laptops and PCs
    • Other Vulnerabilities
  • School Gists
  • Sports
  • News
  • Biafran News
  • Tech
    • Geeks
    • Pogramming
    • Cyber Attacks
    • Malware
    • Security
    • News
Like Our Page - Call us - ambassadorbensons@gmail.com

Welcome to benaija the info talker


Home » Tech » The Essential Programming Rules And Policies

The Essential Programming Rules And Policies

Add This To Del.icio.usTweet/ReTweet ThisShare on FacebookStumbleUpon ThisAdd toTechnoratiDigg This
Subsequently, after coding was made easier than ever b the top programmers, Another geeks was exposed.

The 10 Programing Rules.


rules of coding nasa
The Ten Programing Rules
  1. Restrict all codes to very simple control flow constructs- do not use go to statements, setjmp or longjmp constructs, and direct or indirect recursion.
  2. All loops must have a fixed upper-bond. It must be trivially possible for a checking tool to prove statically that a preset upper-bound on the number of iterations of a loop cannot be exceeded. If the loop-bound cannot be proven statically, the rule is considered violated.
  3. Do not use dynamic memory allocation after initialization.No function should be longer than what can be printed on a single sheet of paper in a satndard reference format with one line per statement and one line per declaration. Typically. this means no more than about 60 lines of code per function.
  4. The assertion density of the code should average to a minimum of two assertions per functiom. Assertions are used to check for anomalous conditions that should never happen in real-life executions. Assertions must always be side-effect free and should be defined as Boolean tests. When an assertion fails, an explicit recovery action must be taken, e.g., by returning an error condition to the caller of the function that carry out the failing assertion. Any assertion for which a static checking tool can prove that it can never fail or never hold violates this rule (I.e., it is not possible to satisfy the rule by adding unhelpful "assert(true)" statements).
  5. Data objects must be declared at the smallest possible level of scope.
  6. The return value of non-void functions must be checked be each calling function, and the validity of parameters must be checked inside each function.
  7. The use of the preprocessor must be limited to the inclusion of header files and simple macro definitions. Token pasting, variable argument lists (ellipses), and recursive macro calls are not allowed. All macros must expand into complete syntactic units. The use of conditional compiltion directives is often also dubious, but cannot always be avoided. This means that there should rarely be justification for more than one or two conditional compilation directives even in large software development efforts beyond the standard boilerplate that avoids multiple inclusion of the same header file. Each such use should be flagged by a tool-based checker and justified in the code. 
  8. The use of pointers should be restricted. Specifically, no more than one level of deferencing is allowed. Pointer dereference operations may not be hidden in macro definitions or inside tupedef  declarations. Function pointers are not allowed or permitted.
  9. All codes must be compiled from the first day of development with all compiler warnings enabled at the compiler's most pedantic setting. All codes must compile with these setting without any warnings. All codes must be checked daily with at least one, but preferable more than one state of the art-static source code analyzer and should pass the analyses with zero warnings.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        .
No part of this content should be copied without a written approval from the author
Posted by Morgan Benson on Sunday, June 12, 2016 - Rating: 4.5
Title : The Essential Programming Rules And Policies
Description : Subsequently, after coding was made easier than ever b the top programmers, Another geeks was exposed. The 10 Programing Rules. T...

Share

Facebook Google+ Twitter

0 Response to "The Essential Programming Rules And Policies"

Post a Comment

I love to hear from you, your comments strengthen me to write more, give me more of them so that I can write more.

Subscribe to: Post Comments (Atom)

Popular Posts

  • Nigeria Is Poor By President Buhari
    Nigeria Is A Poor Country According to President Muhammadu Buhari, Nigeria is now a poor country due to the drop in global oil pric...
  • Bank Workers To Declare Assets By CBN
    CBN orders bank workers to declare assets Abuja - The Central Bank of Nigeria issued a directive orde ring bank workers in all the 19 ...
  • 20 AMAZING THINGS YOU HAVE NEVER HEARD ABOUT NIGERIA.
    You may already know that Nigeria is the largest black nation in the world and the most populous nation in Africa. You may alre...

Trends

Benaija | The Naija News Talker

The Naija News Talker

Contact Form

Name

Email *

Message *

Pages

  • Home

Copyright © 2012 Benaija | The Naija News Talker - All Rights Reserved
Powered by Morgan Benson