On Sun, Nov 29, 2009 at 01:22:15AM +0200, Dotan Cohen wrote:
> > will get the ones that start with capital alphas. if you want initial
> > caps *only* then:
> >
> > grep "^[A-Z][a-z]*$"
> >
> > would match those.
> >
> 
> Thanks. I meant that caps could only be at the beginning of a word,
> not in the middle. Expanding your example, I figured that would be:
> grep "^[A-Z]?[a-z]*$"  // note the question mark

That's clearly a false statement. Here's a snippet from 'strings
/bin/false'

[]A\A]A^A_
fffff.
l$ L
t$(L
|$0H
Usage: %s [ignored command line arguments]
  or:  %s OPTION
Exit with a status code indicating failure.
      --help     display this help and exit
      --version  output version information and exit
NOTE: your shell may have its own version of %s, which usually
supersedes
the version described here.  Please refer to your shell's documentation
for details about the options it supports.
false
Report bugs to <%s>.
bug-coreut...@gnu.org
/usr/share/locale
--help
--version
Jim Meyering
6.10
GNU coreutils
%s (%s) %s
 %s
Written by %s.
Written by %s and %s.
Written by %s, %s, and %s.

-- 
Tzafrir Cohen         | tzaf...@jabber.org | VIM is
http://tzafrir.org.il |                    | a Mutt's
tzaf...@cohens.org.il |                    |  best
ICQ# 16849754         |                    | friend


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to