How do I do this? c#

Hi guys i have this array and i only want to sum the negative numbers and then the positve ones. { static void Main(string[] args) { long[] no = new long[] { -3, -2, -8, 7, 4, 9, }; long sum = 0; foreach (int i in no) { sum += i; } Console.WriteLine(" {0}", sum); Console.ReadLine(); } } }

by IzanagiYin via /r/csharp

Leave a Reply