The following LINQ call should do the trick:
var attrs =
doc.Descendants("Program").First(prog =>
prog.Attribute("ID").Value == "2").Attributes();
Descendants ( ) XML, "". First, , (, "ID", "2" ). , FirstOrDefault, null, . , Attributes .
, LINQ to XML - XML , ( LINQ).