ex02: Correct C implementation of sum.