Microsoft Interview Question

Optimize the following C code to decrease the overall O value