Attempt to count descramblers used properly
[oscam.git] / CODING.RULES.txt
blob0827631ec0058e995ff23f99778d9aa843c77df2
1 /* CODING RULES */\r
2 \r
3 //single line comment\r
4 \r
5 /* #####\r
6  * multi\r
7  * line\r
8  * comment\r
9  */\r
11 #include <stdio.h>\r
13 /* use tab == (4 spaces)\r
14  * or 2tab == (8 spaces)\r
15  * for increment\r
16  * and each level\r
17  */\r
19 //remove spaces at the end of lines\r
21 //one empty line between functions\r
22 const char *idea_options(void){\r
23 <------>if (sizeof(short) != sizeof(IDEA_INT)) // please do not use shortenings\r
24 <------>{\r
25 <------><-->return ("idea(int)");\r
26 <------>} else {\r
27 <------><-->return ("idea(short)");\r
28 <------>}\r
29 }\r
31 //alternative usual notation\r
32 <------>if (sizeof(short) != sizeof(IDEA_INT)) { // please do not use shortenings\r
33 <------><-->return ("idea(int)");\r
34 <------>} else {\r
35 <------><-->return ("idea(short)");\r
36 <------>}\r
37 }\r
39 /* ##########################\r
40  * each function or procedure\r
41  * begins & ends with a brace\r
42  */\r
44 int main(void)\r
45 {\r
46 <------>printf("hello, world\n");\r
47 <------>for (count=1; count < 11; count = count + 1)\r
48 <------>{\r
49 <------><-->printf(" %d\n", count); \r
50 <------>}\r
52 <------>//one empty line between codeblocks\r
53 <------>while(i < x)\r
54 <------>{\r
55 <------><-->printf(" %d\n", i);      \r
56 <------><-->i++;\r
57 <------>}\r
58 <------>exit(0);\r
59 }\r