Updated all spell scripts

This commit is contained in:
Hondacrx
2025-10-13 13:23:31 -04:00
parent 3c4602e4a1
commit 3e028633ba
46 changed files with 33364 additions and 26554 deletions
@@ -203,6 +203,33 @@ namespace System.Collections.Generic
while (list.Count <= index)
list.Add(defaultValue);
}
public static void PartitionInPlace<T>(this IList<T> list, Func<T, bool> predicate)
{
int left = 0;
int right = list.Count - 1;
while (left <= right)
{
while (left <= right && predicate(list[left]))
{
left++;
}
while (left <= right && !predicate(list[right]))
{
right--;
}
if (left < right)
{
T temp = list[left];
list[left] = list[right];
list[right] = temp;
left++;
right--;
}
}
}
}
public interface ICheck<in T>