char by char from a file

This is a discussion on char by char from a file within the C Programming forums, part of the General Programming Boards category; I want to traverse the input file character by character,the file is got thru command line argument. I want to ...

  1. #1
    Lord CyKill
    Guest

    Exclamation char by char from a file

    I want to traverse the input file character by character,the file is got thru command line argument. I want to determine different no of chars and also the frequency of each char!

  2. #2
    Open to suggestions Brighteyes's Avatar
    Join Date
    Mar 2003
    Posts
    204
    This has been done several times, use the search feature of these boards to find everything you want.
    p.s. What the alphabet would look like without q and r.

  3. #3
    Registered User
    Join Date
    Jan 2002
    Location
    Vancouver
    Posts
    2,220

    Re: char by char from a file

    Originally posted by Lord CyKill
    I want to traverse the input file character by character,the file is got thru command line argument. I want to determine different no of chars and also the frequency of each char!
    Code:
    chr = fgetc(fp);

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Formatting the contents of a text file
    By dagorsul in forum C++ Programming
    Replies: 2
    Last Post: 04-29-2008, 01:36 PM
  2. Dikumud
    By maxorator in forum C++ Programming
    Replies: 1
    Last Post: 10-01-2005, 07:39 AM
  3. comparing fields in a text file
    By darfader in forum C Programming
    Replies: 9
    Last Post: 08-22-2003, 09:21 AM
  4. I'm having a problem with data files.
    By OmniMirror in forum C Programming
    Replies: 4
    Last Post: 05-14-2003, 10:40 PM
  5. Need help fixing bugs in data parsing program
    By daluu in forum C Programming
    Replies: 8
    Last Post: 03-27-2003, 06:02 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21