I\'m writing a program that writes output to a file. If this file doesn\'t exist, I want to create it.
Currently, I\'m using the following flags when calling open: O
Note that under POSIX (Unix, Linux, MacOS, etc) you can open and create a file with any permissions you choose, including 0 (no permission for anyone), and yet still write to the file if opened for writing.