Elementary programming in C