You probably confuse "regexps" with "shell regexps" (aka "file globs"). "Regexp" is what commands like sed, awk, grep, etc. use. The shell (and hence "find" uses only "file globs", which are a lot simpler and less sophisticated.
What you can do is to use "find" to pre-sort the files you are interested in and then filter this output through "grep" or a similar tool using regexps, for instance:
find /path/to/startdir -type f -name "*\.c" -print | grep "[01][0-9][0-9][0-9]\.c$"
Note the difference between "*\.c" (file glob, read by shell) and the regexp grep works with.
You can also use "find" with an "-exec" clause to send every file name to a regexp-capable program. "Find" will use the return value (=error level) of that program to determine if it should be included in the result set (=printed) or not. This probably will result in a lot more overhead because the external program is called for every single filename instead of once for the pipeline in the above example.
I hope this helps.
bakunin
PS: As you seem to be a bit unsure about the syntax of "find" you might want to read this article where i explained it in some detail.
Note that with the regex option in find, one needs to match the entire path. Matching arbitrary strings with a regex requires .* , not a stand-alone * :
-regex pattern
File name matches regular expression pattern. This is a match
on the whole path, not a search. For example, to match a file
named `./fubar3', you can use the regular expression `.*bar.' or
`.*b.*3', but not `f.*r3'.
-- excerpt from man find (GNU)
Thanks for the help. I got the output as expected , and now I have more than one option to achieve that:).
I am still not clear on one thing though. Why can not we use shortcuts for the regular expression available- (with grep -E here)? For instance - \d for all numbers , \w for all alphanumerics . Please suggest.