A generator is a generalization of a subroutine, primarily used to simplify the writing of iterators. The yield statement in a generator does not specify a co-routine to jump to, but rather passes a value back to a parent routine.
1
vote
0answers
14 views
99 bottles of beer on the wall + EcmaScript 6
Today, a solution written in Python was posted to this challenge, and since I was inspired by it, I made a version in EcmaScript 6.
I tried to explore some new language constructs:
arrow functions
...
1
vote
0answers
64 views
A class with a function pointer instead of a generator
I am building TiKZ files, one pdf for each image I have. The purpose is to add text to each separately. The images are legion, so I created a script to generate the text files instead of generating ...