Last active
January 13, 2020 14:36
-
-
Save cesarkohl/e9c76bddcb372b74e8774483caa786ad to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| var witches = ['Harry Potter', 'Hermione Granger', 'Ron Weasley']; | |
| // get the iterator | |
| var iteratorWitches = witches [Symbol.iterator] (); | |
| iteratorWow.next (); // {value: Harry Potter, done: false} | |
| iteratorWow.next (); // {value: Hermione Granger, done: false} | |
| iteratorWow.next (); // {value: Ron Weasley, done: false} | |
| iteratorWow.next (); // {value: undefined, done: true} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment