Typos, rework example code build.
Add compilation flags. Use available C++ header instead of C ones (stdio.h -> cstdio).
Initial revision.