-
-
Notifications
You must be signed in to change notification settings - Fork 474
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Iterator: general refactoring and reset method (#193)
Feature Reset allows for the iteration process over a sequence to be restarted from the beginning. It enables reusing the iterator for multiple traversals without needing to recreate it. Refactoring It is a idiomatic practice to design functions and methods to return concrete struct types. This approach promotes flexibility and decoupling, allowing the calling code to work with any implementation that satisfies the interface
- Loading branch information
Showing
3 changed files
with
120 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters