pub fn two_sum<T>(a: T, b: T) -> (T, T)where T: Copy + Add<Output = T> + Sub<Output = T>,
Calculates floating-point sum and error. The 2Sum algorithm.
a
b
returns (a + b) and the floating-point error: $t = a + b - (a \oplus b)$ so: $a+b=s+t$.