pub fn mul<T>(lhs: &PrimitiveArray<T>, rhs: &PrimitiveArray<T>) -> Result<PrimitiveArray<T>>
where
    T: NativeType + Mul<Output = T>,
{
    check_same_type(lhs, rhs)?;

    binary(lhs, rhs, lhs.data_type().clone(), |a, b| a * b)
}
/// Multiplies two primitive arrays with the same type.
/// Panics if the multiplication of one pair of values overflows.
///
/// # Examples
/// ```
/// use arrow2::compute::arithmetics::basic::mul;
/// use arrow2::array::Int32Array;
///
/// let a = Int32Array::from(&[None, Some(6), None, Some(6)]);
/// let b = Int32Array::from(&[Some(5), None, None, Some(6)]);
/// let result = mul(&a, &b).unwrap();
/// let expected = Int32Array::from(&[None, None, None, Some(36)]);
/// assert_eq!(result, expected)
/// ```
Multiplies two primitive arrays with the same type.
Panics if the multiplication of one pair of values overflows.
Multiplies two primitive arrays with the same type . Panics if the multiplication of one pair of values overflows .
pub fn mul<T>(lhs: &PrimitiveArray<T>, rhs: &PrimitiveArray<T>) -> Result<PrimitiveArray<T>>
where
    T: NativeType + Mul<Output = T>,
{
    check_same_type(lhs, rhs)?;
    binary(lhs, rhs, lhs.data_type().clone(), |a, b| a * b)
}
pub fn mul < T > ( lhs : & PrimitiveArray < T > , rhs : & PrimitiveArray < T > ) -> Result < PrimitiveArray < T > > where T : NativeType + Mul < Output = T > , { check_same_type ( lhs , rhs ) ? ; binary ( lhs , rhs , lhs . data_type ( ) . clone ( ) , | a , b | a * b ) }
Multiplies two primitive arrays with the same type.
Multiplies two primitive arrays with the same type .
lhs
&PrimitiveArray<T>
rhs
&PrimitiveArray<T>
lhs
&PrimitiveArray<T>
rhs
&PrimitiveArray<T>
examples
```
use arrow2::compute::arithmetics::basic::mul;
use arrow2::array::Int32Array.

let a = Int32Array::from(&[None, Some(6), None, Some(6)]);
let b = Int32Array::from(&[Some(5), None, None, Some(6)]);
let result = mul(&a, &b).unwrap();
let expected = Int32Array::from(&[None, None, None, Some(36)]);
assert_eq!(result, expected)
```
` ` ` use arrow2 :: compute :: arithmetics :: basic :: mul ; use arrow2 :: array :: Int32Array . let a = Int32Array :: from ( & [ None Some ( 6 ) None Some ( 6 ) ] ) ; let b = Int32Array :: from ( & [ Some ( 5 ) None None Some ( 6 ) ] ) ; let result = mul ( &a &b ) . unwrap () ; let expected = Int32Array :: from ( & [ None None None Some ( 36 ) ] ) ; assert_eq! ( result expected ) ` ` `