I have a list of dynamic objects
List myDynamicList;
where one item would look similar to below:
dynamic d = ne
You can use a list to save all the extension that you need and use Contains extension method in your query:
var list=new List(){".dll", ".exe"};
var libraries = myDynamicList.Where(d => list.Contains(Path.GetExtension(d.FileName)))
.Select(d => d.FileName);
You can also use Any extension method:
var libraries = myDynamicList.Where(d => list.Any(e=>e==Path.GetExtension(d.FileName)))
.Select(d => d.FileName);