#include #include extern int64_t backtest_step(int64_t state, int64_t sample); int main(void) { int64_t s = 0; s = backtest_step(s, 3); /* 0 + 9 */ s = backtest_step(s, 4); /* 9 + 16 */ assert(s == 25); return 0; }