private static void findNewestFile(List list) { foreach (string dir in list) { var directory = new DirectoryInfo(dir); var file
Your code file need to include this:
using System.Linq;
Most probably you are missing using System.Linq
using System.Linq