X-Git-Url: https://git.ralfj.de/rust-101.git/blobdiff_plain/1b77423cf168e5ff2b41667ea67252f4fbc44652..f9bb29fcf0e25966dddd1dca29d70d392a5dfdca:/src/part01.rs diff --git a/src/part01.rs b/src/part01.rs index bff079b..05696a5 100644 --- a/src/part01.rs +++ b/src/part01.rs @@ -89,9 +89,8 @@ pub fn main() { // You will have to replace `part00` by `part01` in the `main` function in // `main.rs` to run this code. -// **Exercise 01.1**: Write a funtion `vec_avg` that computes the average value of a `Vec` (rounded down to -// the next integer). -// -// *Hint*: `vec.len() as i32` returns the length of a vector `vec` as signed integer. +// **Exercise 01.1**: Write a funtion `vec_sum` that computes the sum of all values of a `Vec`. + +// **Exercise 01.2**: Write a function `vec_print` that takes a vector and prints all its elements. // [index](main.html) | [previous](part00.html) | [next](part02.html)