Added C code