Solve problems 47,72 using Rust.