 		}
 		else
 		{
-			return nil
+			assert(value == sequence[middle])
+			return value
 		}
 	}
 

	}
	else
	{
		return nil
	}
}


		}

		let middle = midpoint(min, max)

		if value < sequence[middle]
		{
			max = middle - 1
		}
