This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| kristian@luke:~$ cat foo.c | |
| #include <stdio.h> | |
| void test_function(int i) | |
| { | |
| printf("This function does nothing\n"); | |
| } | |
| int main(void) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| kristian@luke:~$ cat foo.c | |
| #include <stdio.h> | |
| void test_function(int i) | |
| { | |
| printf("This function does nothing\n"); | |
| } | |
| int main(void) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ristian@luke:~$ cat foo.c | |
| #include <stdio.h> | |
| void test_function(int i) | |
| { | |
| printf("This function does nothing\n"); | |
| } | |
| int main(void) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| conf/distributions | |
| Origin: NNP | |
| Suite: stable | |
| Codename: nnp | |
| Components: main | |
| Architectures: amd64 | |
| SignWith: yes | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| test=2; | |
| printf("%s\n", test == 2 ? "TRUE" : "FALSE"); | |
| printf("%s\n", !test == !2 ? "TRUE" : "FALSE"); | |
| Output: | |
| ~$ gcc foo.c | |
| ~$ ./a.out | |
| FALSE |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| TICK TOCK | |
| Proto stats for WEB: 3 | |
| Proto stats for SSH: 24 | |
| TICK TOCK | |
| Proto stats for WEB: 4 | |
| Proto stats for SSH: 25 | |
| TICK TOCK | |
| Proto stats for WEB: 4 | |
| Proto stats for SSH: 26 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ////////////////////////////////////////////////////////////////////////////////// | |
| int load | |
| ( | |
| const char *path, // The path of the def file | |
| struct trie_tree **tree_out // Tier tree (out) | |
| ) | |
| // | |
| // Description: | |
| // | |
| // Loads the def file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| IDENTIFICATION DIVISION. | |
| PROGRAM-ID. HELLO-WORLD. | |
| PROCEDURE DIVISION. | |
| DISPLAY 'Hello, world'. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| kristian@edwin:~$ cat foo2.c; gcc foo2.c; ./a.out | |
| #include <stdio.h> | |
| int main(void) { | |
| int i = 10; | |
| while (i --> 0) | |
| printf("%d ", i); | |
| putchar('\n'); | |
| } | |
| 9 8 7 6 5 4 3 2 1 0 | |
| kristian@edwin:~$ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #define test(n, op) do { \ | |
| int value; \ | |
| printf("Take %d (%s, x: %d, y: %d)\n", n, #op, x,y); \ | |
| printf(#op ": %s ", (value = op) ? "TRUE" : "FALSE"); \ | |
| printf(" X: %d Y: %d\n\n", x, y); \ | |
| } while(0) | |
| int main(void) { |