21 lines
329 B
C
21 lines
329 B
C
|
#include <stdio.h>
|
||
|
#include <stdlib.h>
|
||
|
|
||
|
int add(int a, int b) {
|
||
|
//TODO: change so that the sum of a and b is returned
|
||
|
return 0;
|
||
|
}
|
||
|
|
||
|
|
||
|
int main(int argc, const char *argv[])
|
||
|
{
|
||
|
int a, b, result;
|
||
|
|
||
|
a = atoi(argv[1]);
|
||
|
b = atoi(argv[2]);
|
||
|
result = add(a, b);
|
||
|
|
||
|
printf("The sum of a=%d and b=%d is %d\n", a, b, result);
|
||
|
return 0;
|
||
|
}
|