Side question: maintenece of functional programs is easier, because you don't need to think about state. Could it be used to create a functional programming language, easily understood by non-programmers or beginners , so they too could take a program and adapt it to their needs ? Does such language exist ?
Conversations with a six-year-old on functional programming
41–50 of 319 posts
Re: Conversations with a six-year-old on functional programming
#42Side question: maintenece of functional programs is easier, because you don't need to think about state. Could it be used to create a functional programming language, easily understood by non-programmers or beginners , so they too could take a program and adapt it to their needs ? Does such language exist ?
That's why Excel works for so many people -- the internal and intermediate states can be as visible as the user needs or desires them to be. And those users seem to have no problem chaining together multiple cells into what is essentially a very complex function.
Re: Conversations with a six-year-old on functional programming
#43I wish someone would explain all of Category Theory like this to me .
Re: Conversations with a six-year-old on functional programming
#44When my son was around five or six, I did a similar exercise to explain the difference between prime and composite numbers. I told him that a number X is composite if you can fit X apples into buckets and end up with the same number of apples in each bucket. I drew 6 apples and asked whether they could be divided into buckets with an equal number of apples in each. It was immediately obvious that they could. My son c…
> I told him that a number X is composite if you can fit X apples into buckets and end up with the same number of apples in each bucket. Wrong; X is composite if you can fit X apples into buckets and end up with the same number of apples in each bucket, with at least two apples in each bucket . "You gotta tell the children the truth. They don't need a whole lot of lies. Cause one of these days, baby, they'll be runni…
Re: Conversations with a six-year-old on functional programming
#45If you're interested in learning some of the beautiful foundations of functional programming, I highly recommend checking out the lecture notes and assignments from his Penn CIS 194 class (http://www.cis.upenn.edu/~cis194/spring13/lectures.html)
Re: Conversations with a six-year-old on functional programming
#46Side question: maintenece of functional programs is easier, because you don't need to think about state. Could it be used to create a functional programming language, easily understood by non-programmers or beginners , so they too could take a program and adapt it to their needs ? Does such language exist ?
Re: Conversations with a six-year-old on functional programming
#47The trouble with most math I've encountered isn't the concepts, it's the quality of the abstractions we use to represent and interpret them.
The best(worst) example I can think of is the Alice/Bob description of cryptographic protocols, where somebody's idea of teaching is, "let's take these symbolic representations and instead of just shouting them at you slowly, I will obfuscate them with a set of conceptually unrelated words and repeat the representation word for word in a more patronizing way."
Great piece of writing.
Re: Conversations with a six-year-old on functional programming
#48What is truly astounding about this is the patience to even attempt to explain free theorems to a 6 year old. Most parents would likely answer "math" and that would be the end of it. I don't (yet) have kids, but when I do I hope I have the wherewithal to recognize and take advantage of moments like these.
Explaining things to them and seeing the dawn of understanding in their eyes in easily my greatest joy in life. As a parent, I basically get to relive this xkcd[0], over and over, every day.
We take it to an extreme - we unschool[1]. We do our best to treat our daughters as any other member of the family, expecting to act as adults to the extent that they're able to do so. My nine-year-old spends much of her days right now playing Roblox and Star Stable, but even that is punctuated by her coming to us with random questions about things she's interested in. If I'm not head-down on a project I take the time to explain as best I can. If I'm otherwise occupied I always at least take the time to say "Go search for " and follow up with once I'm free.
The results have, so far, been incredible. Our oldest was a late reader by the standards of the testing done in government schools, but once she ran into something she wanted to do that could only be accomplished by reading, she achieved fluency more quickly than I would have ever expected. For what it's worth, that "something" was an online RPG where she had to do quests to progress. In order to do that, she had to be able to read the quest text.
These days she's engrossed in the "Pegasus" series by Kate O'Hearn, and devouring them at a rate of ~1k pages per week. She'll have finished the series by the end of this week and I'm hoping she'll pick up Asimov's "Norby" series next. If not, she'll find something else that interests her and continue reading well into the wee hours of the morning I'm sure.
0: https://www.xkcd.com/1053/ 1: https://en.wikipedia.org/wiki/Unschooling
Re: Conversations with a six-year-old on functional programming
#49What is truly astounding about this is the patience to even attempt to explain free theorems to a 6 year old. Most parents would likely answer "math" and that would be the end of it. I don't (yet) have kids, but when I do I hope I have the wherewithal to recognize and take advantage of moments like these.
One of the things you figure out is that some kids aren't interested. And if your kid isn't interested in thinking about prime numbers, you're going to be hard pressed to change that. Conversely they will have interests that you don't share, and it's going to be harder for you to participate meaningfully in that beyond being generally supportive. They are individuals that way.
Re: Conversations with a six-year-old on functional programming
#50This is fantastic. Reminds me of Hofstadter's conversations between Achilles and a Tortoise. The trouble with most math I've encountered isn't the concepts, it's the quality of the abstractions we use to represent and interpret them. The best(worst) example I can think of is the Alice/Bob description of cryptographic protocols, where somebody's idea of teaching is, "let's take these symbolic representations and inste…