How do I recursively count all files of a certain type in zsh?
There are quite a few methods to do this (helpful SuperUser questions such as this one give pointers), but few zsh-specific methods.
This follows my previous question - several zsh-specific solutions have been given to me, so I will record them here in case anybody else ever wants to do this.
zshkinda defies "simple"; it's got a lot of functionality and it's hard to describe most of it simply. – geekosaur Apr 09 '12 at 12:57( */.(cpp|h)(.) )sets a as an array of all files matching the glob, and$#agives its size – CharlesB Nov 14 '12 at 10:56