Your example code does not have proper includes, but it is not clear if that is the real code since you would have more errors then, but if it is then they should look like this:
#include <stdio.h>
the other problem is that main
needs a return type:
int main()