Perl exclude directories in command line

Hi,
I use find command to list all the files in a directory and its sub-directories, but the problem is to exclude certain directories during search. Can i give the directory names in command line to skip them and search rest of the directories?
For example i have directories:
test
../test1
../test2
../test1/test11
../test1/test12

etc etc.
When i give test2 and test12 at command line,the script should exclude the given two directories and search for files in the rest of the directories. Any help highly appreciated.
Thanks in advance!

From man find (linux), the -path option may be of use:File name matches shell pattern pattern. The metacharacters do not treat "/" or "." specially; so, for example, find . -path "./sr*sc"
will print an entry for a directory called "./src/misc" (if one exists). To ignore a whole directory tree, use -prune rather than checking every file in the tree. For example, to skip the directory "./src/emacs" and all files and directories under it, and print the names of the other files found, do something like this: find . -path ./src/emacs -prune -o -print
So in your case, you can do:

find .. -path ../test2 -prune -o -path ../test1/test12 -prune -type f -print