The following functions currently return f64 values irrespective of the input Array data's native type.
The above functions need to return the appropriate type value instead of f64. This change is probably going to be
easier to implemented once Typed Arrays are implemented.