Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Iterator/Vec examples #1

Open
4 of 7 tasks
moosingin3space opened this issue Jul 23, 2016 · 2 comments
Open
4 of 7 tasks

Iterator/Vec examples #1

moosingin3space opened this issue Jul 23, 2016 · 2 comments

Comments

@moosingin3space
Copy link

moosingin3space commented Jul 23, 2016

  • Iterate while appending, imperative
  • Iterate while appending, functional
  • Remove elements in-place
  • Filter
  • Borrowck concerns when passing Iterators around
  • Accumulator pattern (fold)
  • Demonstrate what flat_map means

If you can think of any more, leave them in the comments.

@cbreeden
Copy link
Contributor

@moosingin3space I wrote a quick something that takes a reference to an iterator. I don't know if it does a good job explaining the inherent problems. Any ideas?

@moosingin3space
Copy link
Author

@cbreeden I modified your example to show the problem I encountered while learning Rust. For some reason I don't have commit privileges, so I'll have to fork it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants