• + 1 comment
    read n
    read -a arr
    
    temp=${arr[0]}
    for n in ${arr[@]:1}; do temp=$(( temp ^ n )); done
    
    echo $temp