title: Is there a fseek and ftell equivalent from getc files for getchar()?
body: <pre><code>#include &lt;stdio.h&gt;
  #include &lt;stdlib.h&gt;
  #include &lt;unistd.h&gt;
  
  
  int main(int argc, char **argv) {
      int o;
      int w = 80;
      int p = 1;
  
      int c;
      int line_count = 0;
      long remember_pos;
      while ((c = getc(stdin)) != EOF) {
          long num = ftell(stdin);
          printf("%li\n", num);
      }
  }
  </code></pre>
  
  <p>Basically processing the standard input when you do it in unix, like for example</p>
  
  <pre><code>$ gcc -Wall fileabove.c
  $ echo hello | ./a.out
  1
  2
  3
  4
  5
  6
  </code></pre>
  
  <p>I want it to process the 'hello' from echo. I want there to be a way to get to stdin[0] (in file's with fseek). Also get the position we are currently on (in file's with ftell)</p>
  
  <p>OR looking for any other way to keep track of unseekable standard input</p>