var riverslist = new list<string>(); var keycode = generatekeycodefor("rivers"); riverslist.foreach(r => { if (r.disavow("pollution")) { console.writeline("recommence conservation efforts!"); } else { console.writeline("requirement: more preexplanation on river health."); }});