title: What's the C++ equivalent to Java's java.io.FileInputStream.read()?
body: <p>How can I turn the following line of Java to C++ code?</p>
  
  <pre><code> FileInputStream fi = new FileInputStream(f);
   byte[] b = new byte[188];
   int i = 0;
   while ((i = fi.read(b)) &gt; -1)// This is the line that raises my question.
   {
   // Code Block
   }
  </code></pre>
  
  <p>I'm trying to run the following line of code, but it's result is an error.</p>
  
  <pre><code> ifstream InputStream;
   unsigned char *byte = new unsigned char[188];
   while(InputStream.get(byte) &gt; -1)
   {
   // Code Block
   }
  </code></pre>