model view in C