namespace SharedProject.Utils; public static class ValueHelpers { public static T Min(T a, T b) where T : IComparable { return Comparer.Default.Compare(a, b) <= 0 ? a : b; } public static T Max(T a, T b) where T : IComparable { return Comparer.Default.Compare(a, b) >= 0 ? a : b; } }