Talk:File input/output: Difference between revisions

Line 17:
 
When I wrote this task, the purpose was to demonstrate file input and file output, but the overreaching description of the task has let to filesystem operations. Obviously, the task needs to be clarified. Anyone have suggestions? I'm thinking separate tasks each for input and output. I'll get on creating those, and then we can figure out what to do about this task. --[[User:Short Circuit|Short Circuit]] 03:47, 7 October 2008 (UTC)
 
== Binary vs. Text ==
 
:On second thought, I'm not sure how to handle the difference between binary and text-mode files. I'm primarily used to working with binary files in proprietary formats. Separate tasks for text/binary, and a set of each for input and output? --[[User:Short Circuit|Short Circuit]] 03:53, 7 October 2008 (UTC)
:Does [[Basic input loop]] cover text input? --[[User:Mwn3d|Mwn3d]] 03:55, 7 October 2008 (UTC)
 
::On many systems and with many languages there are no special considerations for handling binary vs. text in files. Separate tasks for each could result in duplication without any clarification to the readership. Perhaps one task specifying processing of a binary file and a text file. One might have a task to read a specific binary file and a text file, extract some data from each, and then write the results to a text file. The code implementing that task could then highlight any differences in handling that are required by the language (as well as any portability features that show up for languages that are supported in multiple platforms). For example a Python example would show binfile.read() vs. txtfile.readline(). [[User:JimD|JimD]] 15:17, 20 November 2008 (UTC)
Anonymous user