Open a file without loading it into memory at once
<p>Hi I have a problem to solve for college and I have a hard time understanding the sentence of the problem.</p>

<p>This is the problem I have :</p>

<blockquote>
  <p>Reverse the order of bytes from a file without loading the entire file into memory at once.You have to solve this problem in C# , Java , PHP and Python.</p>
</blockquote>

<p>Now there are two things that I do not understand here.</p>

<p>First I am not sure if bytes refer to the actual characters of the file , or to something else.The problem does not state if it is a text file or not.</p>

<p>Second I am not sure how to open a file without actualy loading into memory.</p>

<p>This is how I would normaly approach this problem , but I think if I do it this way the file gets loaded into memory:</p>

<pre><code>     string fileName = 'file.txt';
     reader = new StreamReader(fileName);

     string line;
     while ((line = reader.ReadLine()) != null)
     {
          Console.WriteLine(line + "\n");
     }
</code></pre>

<p>Also I am not sure how I would actualy reverse all the characters if I am reading it one line at the time.</p>

<p><strong>EDIT</strong> Sorry for posting in multiple languages I do not want the solution for the problem I only want to clarify it so I can solve it myself.I assumed that because I have to solve it in four different languages the concept would apply to all 4 and it did not matter who answer</p>
