 <p>Implement your own printf (on top of vsnprintf to take care of the dirty details) that writes to the console:</p> <pre><code>#include &lt;stdarg.h&gt; int printf(const char *fmt, ...) { char buffer[LARGESIZE]; int rv; va_list ap; va_start(ap, fmt); rv = vsnprintf(buffer, sizeof(buffer), fmt, ap); va_end(ap); Console.WriteLine(buffer); return rv; } </code></pre>