How can I delete a file?

Q

How can I delete a file?

✍: Guest

A

The Standard C Library function is remove. (This is therefore one of the few questions in this section for which the answer is not ``It's system-dependent.'') On older, pre-ANSI Unix systems, remove may not exist, in which case you can try unlink.

2015-04-10, 1036👍, 0💬