fn elem_search<T: PartialEq + Copy>(arr: &Vec<T>, elem: T) -> Option<usize> 
{
    for (i, &pair) in arr.iter().enumerate() 
    {
        if pair == elem 
        {
            return Some(i)
        } 
    }
    None
}
/// Returns the index of the position in the array
Returns the index of the position in the array
Returns the index of the position in the array
fn elem_search<T: PartialEq + Copy>(arr: &Vec<T>, elem: T) -> Option<usize> 
{
    for (i, &pair) in arr.iter().enumerate() 
    {
        if pair == elem 
        {
            return Some(i)
        } 
    }
    None
}
fn elem_search < T : PartialEq + Copy > ( arr : & Vec < T > , elem : T ) -> Option < usize > { for ( i , & pair ) in arr . iter ( ) . enumerate ( ) { if pair == elem { return Some ( i ) } } None }
Returns the index of the position in the array
Returns the index of the position in the array
arr
&Vec<T>
elem
T
arr
&Vec<T>
elem
T