I write simple console functions and use freopen to redirect printf statements to a file. Can the output to the file be “turned off” and the printf outputs redirected back to the console window later in the code?
I write simple console functions and use freopen to redirect printf statements to a
Share
fprintflets you to print to a specific file stream. For example,print
messagein the standard output (the console), so… as you see,printfis just an specialization offprintf.I hope this help.