fn subopt_instance<R: Rng + ?Sized>(num_resources: usize, rng: &mut R) -> Vec<f64> {
    let mut pts = vec![0usize; 2 * num_resources + 1];
    let mut pt = 2 * num_resources - 1;
    let mut i = 0;
    while pt >= num_resources {
        pts[i] = pt;
        pts[i + 1] = pt;
        pt -= 1;
        i += 2;
    }
    pts[i] = num_resources;
    pts.shuffle(rng);
    pts.into_iter().map(|pt| pt as f64).collect()
}
// TODO: should rather return `Vec<usize>`
should rather return `Vec`
should rather return ` Vec `
fn subopt_instance<R: Rng + ?Sized>(num_resources: usize, rng: &mut R) -> Vec<f64> {
    let mut pts = vec![0usize; 2 * num_resources + 1];
    let mut pt = 2 * num_resources - 1;
    let mut i = 0;
    while pt >= num_resources {
        pts[i] = pt;
        pts[i + 1] = pt;
        pt -= 1;
        i += 2;
    }
    pts[i] = num_resources;
    pts.shuffle(rng);
    pts.into_iter().map(|pt| pt as f64).collect()
}
fn subopt_instance < R : Rng + ? Sized > ( num_resources : usize , rng : & mut R ) -> Vec < f64 > { let mut pts = vec ! [ 0usize 2 num_resources 1 ] ; let mut pt = 2 * num_resources - 1 ; let mut i = 0 ; while pt >= num_resources { pts [ i ] = pt ; pts [ i + 1 ] = pt ; pt -= 1 ; i += 2 ; } pts [ i ] = num_resources ; pts . shuffle ( rng ) ; pts . into_iter ( ) . map ( | pt | pt as f64 ) . collect ( ) }
TODO: should rather return `Vec<usize>`
TODO : should rather return ` Vec<usize > `
num_resources
usize
rng
&mut R
num_resources
usize
rng
&mut R