ArmanriazirusterrorRor [E0382]: Préstamo de valor movido: `val` ... hilo

    //resolved by commenting println line
    thread::spawn(move || {
        let val = String::from("hi");
        tx.send(val).unwrap();
       // println!("val is {}", val);
    });
ArmanRiazi