Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Average() [7/10]

static double System.Linq.Enumerable.Average ( this IEnumerable< int > source)
inlinestatic

Definition at line 3705 of file Enumerable.cs.

3706 {
3707 if (source == null)
3708 {
3709 ThrowHelper.ThrowArgumentNullException(ExceptionArgument.source);
3710 }
3711 checked
3712 {
3714 if (!enumerator.MoveNext())
3715 {
3716 ThrowHelper.ThrowNoElementsException();
3717 }
3718 long num = enumerator.Current;
3719 long num2 = 1L;
3720 while (enumerator.MoveNext())
3721 {
3722 num += enumerator.Current;
3723 num2++;
3724 }
3725 return (double)num / (double)num2;
3726 }
3727 }

References System.Collections.Generic.Dictionary< TKey, TValue >.GetEnumerator(), System.L, System.Linq.source, System.Linq.ThrowHelper.ThrowArgumentNullException(), and System.Linq.ThrowHelper.ThrowNoElementsException().