iterator 290

  1. What does the “yield” keyword do?
  2. Calling remove in foreach loop in Java
  3. How to iterate through two lists in parallel?
  4. Build a Basic Python Iterator
  5. Iterator invalidation rules
  6. What is the most effective way to get the index of an iterator of an std::vector?
  7. Difference between Python's Generators and Iterators
  8. How to convert an iterator to a stream?
  9. What exactly are Python's iterator, iterable, and iteration protocols?
  10. How to avoid “ConcurrentModificationException” while removing elements from `ArrayList` while iterating it?
  11. How to implement an STL-style iterator and avoid common pitfalls?
  12. Sorting a vector in descending order
  13. How can I iterate over files in a given directory?
  14. Why use iterators instead of array indices?
  15. Why are Standard iterator ranges [begin, end) instead of [begin, end]?
  16. C++ STL Vectors: Get iterator from index?
  17. Get the first item from an iterable that matches a condition
  18. Convert Iterator to ArrayList
  19. Why is Java's Iterator not an Iterable?
  20. How to correctly implement custom iterators and const_iterators?
  21. Why use non-member begin and end functions in C++11?
  22. What is the reason behind cbegin/cend?
  23. How to reverse a list in Java?
  24. Creating my own Iterators
  25. What happens if you call erase() on a map element while iterating from begin to end?
  26. Why would iterating over a List be faster than indexing through it?
  27. Ruby: How to iterate over a range, but in set increments?
  28. What is the difference between iterator and iterable and how to use them?
  29. how to pick just one item from a generator (in python)?
  30. Difference between Iterator and Listiterator?
  31. What's the 'Ruby way' to iterate over two arrays at once
  32. What does iterator->second mean?
  33. Python list iterator behavior and next(iterator)
  34. Difference between Java Enumeration and Iterator
  35. Deleting elements from STL set while iterating
  36. ArrayIndexOutOfBoundsException when using the ArrayList's iterator
  37. What is the difference between const_iterator and non-const iterator in the C++ STL?
  38. hasNext in Python iterators?
  39. How does zip(*[iter(s)]*n) work in Python?
  40. Is there an expression for an infinite generator?
  41. Getting number of elements in an iterator in Python
  42. How do I write a for loop in bash
  43. What are fail-safe & fail-fast Iterators in Java
  44. When is not a good time to use python generators?
  45. How to navigate through a vector using iterators? (C++)
  46. Performance of traditional for loop vs Iterator/foreach in Java
  47. Why does Java not allow foreach on iterators (only on iterables)?
  48. How to increment an iterator by 2?
  49. Efficient looping through AS3 dictionary
  50. how portable is end iterator decrement?