progs/C1.c
author Christian Urban <christian dot urban at kcl dot ac dot uk>
Mon, 06 Oct 2014 22:57:44 +0100
changeset 216 38718062709a
parent 112 0711775cb6b0
child 217 8ddf4fe6bf31
permissions -rw-r--r--
updated C2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
216
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     1
#include <string.h>
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     2
#include <stdio.h>
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     3
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     4
void dead () {
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     5
  printf("I will never be printed!");
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     6
}
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     7
105
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff changeset
     8
216
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
     9
int main(int argc, char **argv) {
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
    10
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
    11
  char buffer[8];
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
    12
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
    13
  strcpy(buffer, argv[1]);
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
    14
38718062709a updated C2
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 112
diff changeset
    15
  return 1;
105
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff changeset
    16
}
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff changeset
    17
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff changeset
    18
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff changeset
    19
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff changeset
    20