<span style="font-size:18px;">DirectoryInfo dir = new DirectoryInfo(path);
FileInfo[] files = dir.GetFiles();</span>
<span style="font-size:18px;">for(int i=0;i<files.Length;i++){</span>
<span style="font-size:18px;"><span style="white-space:pre"> </span>if(files[i].Name == name){</span>
<span style="font-size:18px;"><span style="white-space:pre"> </span>break;</span>
<span style="font-size:18px;"><span style="white-space:pre"> </span>}</span>
<span style="font-size:18px;">}</span>
<span style="font-size:18px;">
</span>
<span style="font-size:18px;">超简单的</span>