On Sun, 2004-11-07 at 21:33, Timothy Pick wrote:
> Chris Downie wrote:
> > Hi,
> > 
> > I have a text file that I need to count exactly how many times a  
> > particular character appears. Can someone offer me the correct grep 
> > syntax  to achieve this?
> > 
> > Cheers,
> > Chris
> 
> 
> grep a .xinitrc -o -c
> seems to count how many a's in my .xinitrc file...
> -c == count
> -o == only the part of the line that matches

no, it counts the lines, if "a" is repeated in a line it is only counted
once.

I don't know the answer, but i don't believe thats it!


Reply via email to