1 2 3 4 5 6 7 8 9 10 11 12 13 14
// ripex-lang-test: C math impl — arrays, function pointers. #include "math.h" int add(int a, int b) { return a + b; } int sum(int* xs, int n) { int total = 0; for (int i = 0; i < n; i++) { total += xs[i]; } return total; }