How do I break out of a foreach loop in C# if one of the elements meets the requirement?
foreach
For example:
foreach(string s in sList){
You could avoid explicit loops by taking the LINQ route:
sList.Any(s => s.Equals("ok"))