>who wrote the functions printf, scanf .
You mean who "writes" the functions. Generally every new compiler re-implements printf and most or all of the standard library and the author of the compiler does it (or someone on the team if there's more than one programmer).
>what is it's sourcr code?
I'll attach an example implementation of C89's stdio library.