anchor.diff:          //keyNotFound ""
           raise <| System.Collections.Generic.KeyNotFoundException ()
   
  +//
  +[<CompiledName("Concat")>]
  +let concat (resizeArrays : seq<ResizeArray<'T>>) : ResizeArray<'T> =
  +    // Preconditions
  +    checkNonNull "resizeArrays" resizeArrays
  +
  +    let flattened = ResizeArray ()
  +    for resizeArray in resizeArrays do
  +        flattened.AddRange resizeArray
  +    flattened
  +    
  +//
  +[<CompiledName("Append")>]
  +let append (resizeArray1 : ResizeArray<'T>) (resizeArray2 : ResizeArray<'T>) : ResizeArray<'T> =
  +    // Preconditions
  +    checkNonNull "resizeArray1" resizeArray1
  +    checkNonNull "resizeArray2" resizeArray2
  +
  +    let combined = ResizeArray (resizeArray1.Count + resizeArray2.Count)
  +    combined.AddRange resizeArray1
  +    combined.AddRange resizeArray2
  +    combined
  +
  +//
  +[<CompiledName("Sub")>]
  +let sub (resizeArray : ResizeArray<'T>) start count : ResizeArray<'T> =
  +    // Preconditions
  +    checkNonNull "resizeArray" resizeArray
  +    if start < 0 then
  +        invalidArg "start" "The start index cannot be less than zero (0)."
  +    elif count < 0 then
  +        invalidArg "count" "The number of elements to copy cannot be less than zero (0)."
  +    elif start + count > length resizeArray then
  +        invalidArg "count" "There are fewer than 'count' elements between the 'start' index and the end of the collection."
  +    
  +    resizeArray.GetRange (start, count)
  +
  +//
  +[<CompiledName("Fill")>]
  +let fill (resizeArray : ResizeArray<'T>) start count value : unit =
  +    // Preconditions
  +    checkNonNull "resizeArray" resizeArray
  +    if start < 0 then
  +        invalidArg "start" "The start index cannot be less than zero (0)."
  +    elif count < 0 then
  +        invalidArg "count" "The number of elements to copy cannot be less than zero (0)."
  +    elif start + count > length resizeArray then
  +        invalidArg "count" "There are fewer than 'count' elements between the 'start' index and the end of the collection."
  +    
  +    // Overwrite the items within the range using the specified value.
  +    for i = start to start + count - 1 do
  +        resizeArray.[i] <- value
  +
  +//
  +[<CompiledName("Copy")>]
  +let inline copy (resizeArray : ResizeArray<'T>) : ResizeArray<'T> =
  +    ResizeArray (resizeArray)
  +
  +//
  +[<CompiledName("Singleton")>]
  +let singleton value : ResizeArray<'T> =
  +    let resizeArray = ResizeArray ()
  +    resizeArray.Add value
  +    resizeArray
  +
  +
   
   (* Functions below this point still need to be cleaned up. *)
  -
  -//
  -[<CompiledName("Concat")>]
  -let concat (arrs: ResizeArray<'T> list) = new ResizeArray<_> (seq { for arr in arrs do for x in arr do yield x })
  -    
  -//
  -[<CompiledName("Append")>]
  -let append (arr1: ResizeArray<'T>) (arr2: ResizeArray<'T>) = concat [arr1; arr2]
  -
  -//
  -[<CompiledName("Unzip")>]
  -let sub (arr: ResizeArray<'T>) start len =
  -    if start < 0 then invalidArg "start" "index must be positive"
  -    if len < 0 then invalidArg "len" "length must be positive"
  -    if start + len > length arr then invalidArg "len" "length must be positive"
  -    new ResizeArray<_> (seq { for i in start .. start+len-1 -> arr.[i] })
  -
  -//
  -[<CompiledName("Fill")>]
  -let fill (arr: ResizeArray<'T>) (start: int) (len: int) (x:'T) =
  -    if start < 0 then invalidArg "start" "index must be positive"
  -    if len < 0 then invalidArg "len" "length must be positive"
  -    if start + len > length arr then invalidArg "len" "length must be positive"
  -    for i = start to start + len - 1 do 
  -        arr.[i] <- x
  -
  -//
  -[<CompiledName("Copy")>]
  -let inline copy (arr: ResizeArray<'T>) = ResizeArray<_>(arr)
  -
  -let inline private indexNotFound () =
  -    keyNotFound "An index satisfying the predicate was not found in the collection"
   
   //
   [<CompiledName("Iter2")>]
  
positive.code:     for i = 0 to length arr - 1 do 
          let x = arr.[i] 
          if f x then res1.Add(x) else res2.Add(x)
      res1, res2
negative.code:     loop 0
  
  //
  [<CompiledName("FoldSub")>]
  let foldSub f acc (arr: ResizeArray<_>) start fin = 
      let mutable res = acc
  