From d377bcf41f66436b2f43771910dc8fae1a3cff6a Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Fri, 19 Jun 2015 22:51:00 +0200 Subject: [PATCH 1/1] extend ex01.1 hint --- src/part01.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/part01.rs b/src/part01.rs index dc97d8d..bff079b 100644 --- a/src/part01.rs +++ b/src/part01.rs @@ -89,8 +89,9 @@ 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`. +// **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()` returns the length of a vector `vec`. +// *Hint*: `vec.len() as i32` returns the length of a vector `vec` as signed integer. // [index](main.html) | [previous](part00.html) | [next](part02.html) -- 2.30.2