You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: jump_search.rs
    path of file: ./repos/al-go-rithms/search/jump_search/Rust
    
    the code of the file until where you have to start completion: // Jump Search implementation in Rust by Jay9596
use std::cmp::min;

fn jump_search(arr: Vec<i32>,n :i32) -> i32 {
    let len = arr.len();
    //Step size calculated usinf length of array
    let mut step = (len as f64).sqrt() as usize;
    let mut prev: usize = 0;
    
    //Jumps block using step size
    while ar
    
fn jump_search(arr: Vec<i32>,n :i32) -> i32 {
    let len = arr.len();
    //Step size calculated usinf length of array
    let mut step = (len as f64).sqrt() as usize;
    let mut prev: usize = 0;
    
    //Jumps block using step size
    while arr[min(step, len)-1] < n {
        prev = step;
        step += step;
        if prev >= len {
            return -1
        }
    }
    // Linear search
    while arr[prev] < n {
        prev += 1 ;
        if arr[prev] == (min(step, len)) as i32 {
            return -1
        }
    }
    // Element found
    if arr[prev] == n {
        return prev as i32
    }
    -1
}