diff --git a/tests/t003.cxl b/tests/t003.cxl new file mode 100644 index 0000000..16355b6 --- /dev/null +++ b/tests/t003.cxl @@ -0,0 +1,19 @@ +#include + +int sum(int * arr) +{ + int s; + for (s = 0; *arr != 0; arr++) + { + s += *arr; + } + return s; +} + +int main(int argc, char * argv[]) +{ + int a[] = {5, 6, 7, 0}; + int b[] = {10, 20, -500, 0}; + printf("%d;%d\n", sum(a), sum(b)); + return 0; +} diff --git a/tests/t003.x b/tests/t003.x new file mode 100644 index 0000000..dd58918 --- /dev/null +++ b/tests/t003.x @@ -0,0 +1 @@ +18;-470