title: How to get list of directories containing particular file using c#
body: <p>I wish to get list of all the folders/directories that has a particular file in it. How do I do this using C# code.</p>
  
  <p>Eg: Consider I have 20 folders of which 7 of them have a file named "abc.txt". I wish to know all folders that has the file "abc.txt".</p>
  
  <p>I know that we can do this by looking thru all the folders in the path and for each check if the File.Exists(filename); But I wish to know if there is any other way of doing the same rather than looping through all the folder (which may me little time consuming in the case when there are many folders).</p>
  
  <p>Thanks<br>
  -Nayan</p>