Question: what is the difference between open() fopen?
Answer: open() is a system call and specific to Unix-based systems and it returns a file descriptor. You can write to a file descriptor using write() which is another system call. fopen() is an ANSI C function call which returns a file pointer and it is portable to other OSes.