I use find to search for files in a directory and its subdirectories.
find . -iname '*.csv', and it gives me the following output
./2012/t1.csv ./2012/t2.csv ./2013/t1.csv
Now, I want to check in a script whether the file t1.csv is in the current folder or in one of the subdirectories. If its in a subdirectory, my script should descend to that directory. How can I do that?