3 ms·
How many kids, and what ages are they? My daughter's 10th grade programming teacher (<3 you, Mister Serota) had a pretty brilliant mechanic for teaching functi
by bmelton 7y ago
How many kids, and what ages are they?
My daughter's 10th grade programming teacher (<3 you, Mister Serota) had a pretty brilliant mechanic for teaching functions to kids in his class that he relayed to me, and which I will attempt to relay to you.
Effectively, he simply assigned some of the children in class to be 'a function.' Whatever input he gave them, they would have a predetermined routine to execute and give him output. E.g., "Billy, your function adds 2 to whatever input is given. Barbara, your function is to divide everything by 2. Samantha, your function is to determine whether or not dividing something by 2 will leave a remainder (modulo)."
Then he would work complex computations through the room with scripts he'd devised, showing the power of chaining functions together. Similarly, if you give Billy the "+2" function, and then give him an input value of "A", well, he might come back with "C" as the output, or he might come back with puzzlement, and you can teach error handling. Similarly, you can assign multiple kids the same functions (and show asynchrony, or hand them different bad values to show the possibility of inconsistent code).
TLDR: You "program" the children to be functions, feed them data, and then play around with how to best illustrate the concepts by manipulating the inputs and how you string them together.
- Schiphol 7y agoThat's a fantastic idea. Thanks for taking the time to explain it.