{
ifstream filelist("filelist.txt");
std::string filename,filename1;
while(!filelist.eof()) {
   filelist >> filename;
   filename1= "rfio:/castor/cern.ch/cms" + filename;
   cout << filename1 << endl;
   TFile *f =TFile::Open(filename1.c_str());
   TTree *events = (TTree*)f->Get("Events");
   events->SetScanField(0);
   events->Scan("SiStripClusteredmNewDetSetVector_siStripClusters__Rec.obj.@m_data.size():recoTracks_ctfWithMaterialTracksP5__Rec.@obj.size():EventAuxiliary.id_.event_","SiStripClusteredmNewDetSetVector_siStripClusters__Rec.obj.@m_ids.size()>40|recoTracks_ctfWithMaterialTracksP5__Rec.@obj.size()>1");
   f->Close();
   cout << "file closed" << endl;
   }
}
