There are different ways to convert types in Rust.
Learn From and Into with @RustCast video : traits From and Into
A useful Stackoverflow post : How do I convert between numeric types safely and idiomatically?
Another one : What is the difference between From::from and as in Rust?
A nice post by GradCypert.com : From and Into in Rust