Top "File-io" questions

File I/O is input/output that involves the file system.

Read int values from a text file in C

I have a text file that contains the following three lines: 12 5 6 4 2 7 9 I can use the fscanf function to read the …

c file file-io scanf line
How to delete all files older than 3 days when "Argument list too long"?

I've got a log file directory that has 82000 files and directories in it (about half and half). I need to …

linux file-io resource-cleanup
What is a good way to handle exceptions when trying to read a file in python?

I want to read a .csv file in python. I don't know if the file exists. My current solution is …

python python-2.7 exception file-io
File being used by another process after using File.Create()

I'm trying to detect if a file exists at runtime, if not, create it. However I'm getting this error when …

c# file-io
C fopen vs open

Is there any reason (other than syntactic ones) that you'd want to use FILE *fdopen(int fd, const char *mode); …

c linux unix file-io fopen
List all files from a directory recursively with Java

I have this function that prints the name of all the files in a directory recursively. The problem is that …

java file-io
Append TimeStamp to a File Name

I have come across this problem several times in which I would like to have multiple versions of the same …

c# .net file datetime file-io
Closing a file after File.Create

I check to see if a file exists with if(!File.Exists(myPath)) { File.Create(myPath); } However, when I go …

c# file-io
Getting the inputstream from a classpath resource (XML file)

In Java web application, Suppose if I want to get the InputStream of an XML file, which is placed in …

java file-io inputstream