mirror of
https://github.com/kmc7468/cs220.git
synced 2025-12-15 22:48:45 +00:00
polish
This commit is contained in:
@@ -9,7 +9,6 @@ enum Yielded<T> {
|
||||
}
|
||||
|
||||
/// Generator
|
||||
/// - kk
|
||||
/// - You can call `next()` method to get the next value.
|
||||
/// - The generator should stop when it yields `Yielded::Stop`.
|
||||
///
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//! The primary goal of this assignment is to understand generics, traits, and lifetimes.
|
||||
//!
|
||||
//! You should fill out the `todo!()` placeholders in such a way that `/scripts/grade-07.sh` works fine.
|
||||
//! See `assignment07_grade.rs` and `/scripts/grade-07.sh` for the test script.
|
||||
//! See `assignment07/*_grade.rs` and `/scripts/grade-07.sh` for the test script.
|
||||
|
||||
pub mod generator;
|
||||
pub mod my_itertools;
|
||||
|
||||
@@ -52,7 +52,7 @@ pub fn fib<T>(first: T, second: T) -> impl Iterator<Item = T>
|
||||
where
|
||||
T: std::ops::Add<Output = T> + Copy,
|
||||
{
|
||||
todo!("remove below");
|
||||
todo!("replace `std::iter::empty() with your owm implementation`");
|
||||
std::iter::empty()
|
||||
}
|
||||
|
||||
@@ -86,7 +86,7 @@ impl Iterator for RangeIter {
|
||||
|
||||
/// Returns an iterator over the range [left, right) with the given step.
|
||||
pub fn range(left: Endpoint, right: Endpoint, step: isize) -> impl Iterator<Item = isize> {
|
||||
todo!("remove below");
|
||||
todo!("replace `std::iter::empty() with your owm implementation`");
|
||||
std::iter::empty()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user