added C code and updated readme
failed merge