Suppose you are given these classes

class Commit  
{
    public int RepoId { get; set; }
    public List<File> Files { get; set; }
}

class File  
{
    public string FileExtenstion { get; set; }
}

var commits = new List<Commit>  
            {
                new Commit { RepoId = 1, Files = new List<File> {new File { FileExtenstion = "cs"}, new File { FileExtenstion = "js"}}},
                new Commit { RepoId = 2, Files = new List<File> {new File { FileExtenstion = "txt"}, new File { FileExtenstion = "cs"}}}
            };

... and you need to find all commits with RepoId of 1 and FileExtension of "cs".

There are two ways that I know of to do it. One is with Any():

var list = commits.Where(s => s.RepoId == 1 && s.Files.Any(a => a.FileExtenstion == "cs"));  

Another way is with SelectMany():

var list2 = commits.SelectMany(s => s.Files, (s,d) => new {Commit =  s, File = d })  
                        .Where(w => w.Commit.RepoId == 1 && w.File.FileExtenstion == "cs")
                        .Select(s => s.Commit);

Both produce the same result, but what is very powerfull in SelectMany is that it has an overload where you can specify projection. Without projection SelectMany() flattens the hierarchy and returns the bottom in the hierarchy object (in this case it would have been File). In case we need not only flatten but have higher level objects present in the result, that overload comes very handy.