add test 3
This commit is contained in:
1 parent
ca929b5ecd
commit
273cdbcbf8
2 files changed
+20
No files matched your search
@@ -0,0 +1,19 @@
|
||||
#include <stdio.h>
|
||||
|
||||
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;
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
18;-470
|
||||
Reference in new issue
Block a user