X-Git-Url: https://git.ralfj.de/rust-101.git/blobdiff_plain/f5a79e8aaa07e56cf2dd8fe8438d96624dd84fbc..d9fc9a4d89d8e4950f43308318962d9179bd1177:/src/part05.rs?ds=sidebyside diff --git a/src/part05.rs b/src/part05.rs index 03c10d3..84f14ff 100644 --- a/src/part05.rs +++ b/src/part05.rs @@ -110,6 +110,9 @@ impl Clone for SomethingOrNothing { // Again, Rust will generate this implementation automatically if you add // `#[derive(Clone)]` right before the definition of `SomethingOrNothing`. +// **Exercise 05.2**: Write some more functions on `BigInt`. What about a function that returns the number of +// digits? The number of non-zero digits? The smallest/largest digit? + // ## Mutation + aliasing considered harmful (part 2) // Now that we know how to borrow a part of an `enum` (like `v` above), there's another example for why we // have to rule out mutation in the presence of aliasing. First, we define an `enum` that can hold either