This document contains some of the coding standards that the students have to follow , when they
are writing the programs.
Indent style :
- Indent the entire body of each function to one level of indentation.
- Use three spaces or tab per level of indent.
- Select the size of the indentation you prefer and uniformly apply that throughout the program.
- If there are several levels of indentation, each level should be intended the same additional amount of space.
- Indent the statement/s in the body of an if statement
- If a statement is split across two or more lines, indent all subsequent lines.
- Indent the statement/s in the body of an while/for statements.
Comments:
- Describe the purpose of each function in the program using a comment
- Add a comment to the right brace } of every function, to indicate the end of function.
- Add comments to describe the purpose of the statements in the program
Example:
Statements:
- Separate the definitions and executable statements in a function with one blank line.
- Place a blank line before and after every if statement.
White spaces:
- Place a space after each comma(,) in printf and scanf statements.
- Place space on either side of a operator
- Unary operators should be placed directly next to their operands with no intervening spaces.
Naming conventions:
- Choose meaningful variable name.
- When there are multiple words in a variable, begin each after the with a capital letter camel case (eg: totalCommissions)
Programming practices:
- Try to avoid using more than three levels of nesting in loops.
If you are looking for WHAT IS THE MEANING OF DIFFERENTIATION, go through this link
ReplyDeletehttps://mathsforit.blogspot.com/2019/11/what-is-meaning-of-differentiation.html?showComment=1595915476932#c6614167742183095589