Realism in teaching examples/questions is a bit of a red herring. Corporate education particularly loves the buzzword of 'business-relevant', but I think it's often actively harmful.
When you're teaching something new, you want to be able to isolate that concept/technique and focus in on it. A simplified example, or a question with strict parameters, both allow the student(s) to concentrate on the key idea.
If you want to teach someone about SELECT in SQL, for example, it's useful to abstract away the database setup for that particular lesson. It's also useful to use a simplified database concerned with familiar entities, so that SELECT remains the focus rather than one new element of many.
Of course, these simplified examples shouldn't be used in isolation. Instead, you should have a number of them, eaching illustrating/assessing some small point or idea. Once the students have absorbed those ideas, then you start combining the initial building blocks into more complex ideas, just as you'd take a tiered approach when testing software; start with unit tests, then build up.
While I think that you are right, but the right level of abstraction is super important. Here teachers should try to look at the business relevant applications. In university we had one course on databases. This was introduced by means of formal relational databases and relational algebra. Most of the students explained the stuff to each other by working with the more concrete translation in SQL. So if you had problems understanding what the restriction operation (σ) did, somebody told you that it maps to a SELECT in SQL.
What's interesting is that I had my one database course in college that taught relational algebra. We had access to an Oracle database against which we probably only wrote a handful of queries. Almost all of the work was, well, math and theory.
When I got my first development job, I started out scribbling relational algebra on scrap paper and then translating it to SQL. I got faster and faster until I could think in SQL.
Agreed; you have to find a level that clicks for your students otherwise you're just throwing jargon at them. It's difficult to balance because knowing the subject well is required to teach it well, but knowing the subject well also means that your preferred abstractions are going to be too complicated [1].
A lot of people who want/need to understand the broad strokes of a database and how to query it effectively don't need to understand the deep, deep under-pinnings, and (unless you approach it cautiously) diving into it all will be actively counter-productive.
There should be examples (saying things like "oh, by the way, the projection operator is the SELECT clause of a SQL query" costs literally zero) but theory is important.
People who don't understand relational theory can't write SQL to save their lives.
I've seen schemas that literally made me scream.
I think the same applies to algorithms and data structures, e.g. red-black trees from the Cormen are literally std::map.
I found it to be a bit of a chicken-and-egg problem. At the time I learned it, I didn't really understand why relational theory was important. I trusted that it was, I just didn't really grok all of it. But later I found it of immense practical help when writing, and especially debugging, sql queries.
Perhaps the ideal order to learn in would be practical, theoretical, practical (applied theoretical), though that's just a gut feeling.
I dunno. I learned relational theory in college along with SQL. Since then, I've forgotten all of relational theory since I never used it for anything, but my SQL has improved quite a lot through use.
I'm thinking you may have a third variable problem here; people who write sucky SQL tend not to have spent a lot of time thinking about how to write non-sucky SQL. People who write non-sucky SQL have. The former has nearly zero chance to have been exposed to relational theory...the latter has a non-zero chance to have been. Correlation /= causation and all that, and the actual causative variable is time spent learning how to write non-sucky SQL.
> People who don't understand relational theory can't write SQL to save their lives.
Source?
From anecdotal experience, I've seen countless developers write reasonably acceptable SQL without even knowing relational algebra exists in the first place.
I disagree with this traditional pedagogical approach. Learning is much easier when motivated by a complex problem to solve that requires learning and applying multiple "building block" concepts. Start big, then learn small.
It seems counter-intuitive, but I've found that this works for me also. For example, I could never learn basic mathematical concepts until I had seem them in action as a part of a larger framework or practical problem.
For example, differentiation by itself is just pushing symbols around according to some arbitrary-seeming rules. It's not until I did physics that its purpose made sense. I studied calculus for years, and it never "clicked" for me, and I forgot most of it promptly. Then in just a semester of physics where I was applying it in the context of complicated problems, it suddenly felt like second-nature. I had to basically re-learn all of it from scratch, but with the context of my physics problems it was so easy!
I've had similar experiences teaching programming to junior staff. Anything you talk about in isolation goes in one ear and out the other. They have to encounter the problem in something larger that they are solving for the solution to make sense and motivate them to learn.
An example is string-escaping. E.g.: how do you represent the quote symbol in a quoted string? This seems trivial, but it trips up everyone when they are getting started. I mean literally everyone. So okay, I make sure to cover it in like... lesson #1 or #2 because string literals are everywhere, and escaping is common. Every single time, the people that sat through that lesson will ask me a week later to help me fix as program that has a literal like 'O'Brian' in it, and they can't figure out why it's broken. But once I show them that they should have used 'O''Brian' or 'O\'Brian', it all makes sense to them and they memorise the technique.
Yes. I always found it odd, especially in mathematical textbooks, but to some degree also other areas, when a field is explained top down from a theory that is the end result of hundreds of years of discovery, fiddling and trial and error. As if that whole theory was god given and just happened without motivation or process. Besides making it harder to understand by going abstract idea first, it also makes it harder to develop an understanding for how people come up with and improve ideas over time.
About 20 years ago I read a book on spread spectrum radio. Unlike all the others each chapter was in three parts. The first part explained the problem. The things people tried to solve it. Problems with those solutions. And then second part explained the canonical solution, how it solved issues. The third was a formal description and analysis
That book was totally great. Even if you got lost in the math reading the last formal part you understood what was going on.
It makes complete sense for mathematics. Few of the mathematicians I know have any interest in applying math to much of anything besides math research. The whole business is entirely abstract.
I dont see how it is easier. Maybe it is motivating for someone, but I never found it easier to deal with complex problems first and only then moving to simple one. For me, it was easier to learn simple things first. And "do simple thing first" also seems to work much better at my kids, no matter what I am teaching them.
I find it motivating to have the story of how someone uses the skill to solve a complex real-world problem. I think you are right that it is overwhelming to start out by solving that complex large-scope problem first.
Absolutely, but that's a framing device/motivational aspect, rather than the mechanics of the actual learning.
"Here's what we're aiming for, and here's why it matters" should be the introduction, setting the scene and establishing the flow, but then you introduce the various blocks-that-will-be-built and start working up to them in the stepped fashion.
I think the missing link is going from a real world application to a practical teaching problem. A topic that motivates an audience would also depend on the audience.
Trying to think of a good example reminds me of a puzzle game; and how sometimes the contrived puzzles in such games can be obtuse or phrased poorly because they really don't want to give away the answer.
The example should start with an unsolvable problem, then simplify aspects to make it more of an estimation model; which is a useful skill as well.
That requires for the person to actually care about the complex problem, otherwise they'll ignore it and focus on the the individual building blocks in isolation.
Oh man, I have some vitriolic opinions on the sate of modern teaching -- especially vis-à-vis textbooks and written "pedagogy" that go crazy with this "isolation," "abstraction," and "distillation" of the concept: I hate it, please stop doing this.
I feel even more strongly about this for mathematics and computer science: you cannot strip away the context of a technique/idea/concept, and hope to have people understand why it's useful. For example, I'm currently self-teaching myself mathematics. Calculus and its techniques (integration, differentiation, solving PDEs/ODEs, whatever) are easy -- when you understand the context: physical mechanics. Strip that away and what do you get? Symbols and equations that have zero meaning in the real world. It's effectively indistinguishable from GPT-3 text -- it's utter nonsense that doesn't make any sense unless you've already learned the concepts somewhere else, and can piece together what the hell the author is trying to get across (sometimes, the author doesn't even know, but pretends to know!).
Same with probability and statistics. I cannot understand the sheer myopia needed to completely strip away probability from its gambling context: how does this benefit learners? I wasn't able to teach myself these things from regular stats & prob books, because it's schizophrenic gibberish without any context -- without even a single example of a practical application, much less "why is this useful? Why was this brought into the world? Why are you using Brownian Motion for actions of living things???" And then I picked up some theory of gambling books, and lo and behold everything makes sense. There is no cruft. There are no "gotchas" where you need to slam your head against the desk, and force yourself through the problems for it to "click"; everything just clicks because you understand why a certain technique or concept exists, and where it's applicable.
In short, the original context that lead to the creation of a certain technique/concept is enough of a "stage" to teach it; anything more abstract and you're cutting through bone.
Yes; a lot of tech (and other subjects, but especially tech) education is sadly low-quality, being either way too surface-level (learn to make a Twitter clone in 20 minutes by coping & pasting) or far too arcane and assuming a lot of prior knowledge.
I think we're making progress though - we know how to be more effective, but it's a slow process to get there. Mastery of a subject does not necessarily include mastery of how to effectively teach it, and we need to start treating the 'education' bit of 'tech education' as an important and separate element requiring expertise.
I don't understand why so many people think that real-world problems and "true learning" or whatever have to be mutually exclusive.
My applied probability and statistics course for engineers was all about manufacturing quality control. We didn't have magic urns with colored balls that no one cared about. But we did pull samples off the line for destructive testing. Imagining myself troubleshooting a manufacturing problem made me more creative, tenacious, and engaged than if it was a sterile math problem with no context.
Point is, you don't necessarily have to lose anything when making a topic more relatable.
University education, in general, suffers from the implicit assumption that everyone should think like a savant. It's even worse when a topic was invented or discovered to solve a real problem, as opposed to base research, and the teaching strips all context and motivation from the presentation.
I see some other comments criticizing classes that teach certain software tools at the expense of concepts. And yeah, that's training, not education.
I've literally been told by a person before that because my example used in a discussion had no relevance to anything that might happen in THEIR life, that it was a pointless and useless example. They later toned it down to "not as good as theirs", but I digress.
If I could tell the world one thing right now, in regards to this topic, it would be this.
"You, yes you, have NO RIGHT to diss or judge an example made by someone else; when the sole reason of said example is to try to share understanding of a certain lesson or fact. Even if the example is not as great as it could or should be, the act of yourself judging that example completely ignores the fact that YOU didn't fucking know anything about that thing in the first place; hence why an EXAMPLE was needed. That's all it is, now get over yourselves. P.S. Also stop trying to be moral police, none of you have any right to do that either, hypocrites."
I say this in regards to the world, because while it was just that one person who did that, that day; I have heard similar arguments as per the article title and my own experience of running into a fuckwit like that fellow, just with other people over the years.
I don't know why these people think they have a right to judge everything, since they know barely anything. Which means they have a right to do fuck all, and that's that.
P.S. The hypocrite part was added because a large populous on earth always needs to be reminded of that. Always...
I'm having a hard time judging which behavior is less mature:
* the student who tried to convert their own personal discomfort into the wildly exaggerated general conclusion that your example was "pointless and useless"
* the fact that you apparently cannot entertain the truism that examples which students can relate to are generally superior than ones that are difficult for them to relate to
* your bizarre implied learning process where criticism and judgement are reserved only for those who already understand a concept. It's like the scientific process, except upside down. :)
1.> * your bizarre implied learning process where criticism and judgement are reserved only for those who already understand a concept. It's like the scientific process, except upside down. :)
Yes, because this is totally going to get me to agree with you on anything at all. Do you not realize that by writing this, you have declared yourself for all to see that you are the problem? Most of the time, when people resort to attacks like yours here, it's because they have nothing worthwhile to say.
2. >* the fact that you apparently cannot entertain the truism that examples which students can relate to are generally superior than ones that are difficult for them to relate to
You might want to look in the mirror here pal, cause you seem to be projecting.
The fact you think that I have to cater to anyone just because they deem it so, is fucking asinine. Like seriously, are you sure you even have any right to be talking right now? Did you even bother to read my comment properly before writing your sad excuse of criticism?
3. > * the student who tried to convert their own personal discomfort into the wildly exaggerated general conclusion that your example was "pointless and useless"
I said "Person" not "student". See #2 again, the part about reading properly.
4. > Two of these are under your control to change.
All of the things in my life are under my control to change, but only if I desire to go through with the trouble of changing those things. Believe me, if I were to get started on changing the things under my control; dumb fucks like you wouldn't be sharing their opinions anywhere to anyone.
Start focusing on yourself, and less on others; especially me. Don't fucking bother me ever again you god damn ignorate hypocrite.
Real world examples tend to have a huge amount of unpleasant details which hinder transfer of the underlying concepts. We teach one step at a time, and even then 99.999% of the people leave before finishing. Suppose you start teaching arithmetics by introducing 5 year olds to elliptic curves…
In high school I had a chemistry teacher that came from the industry. His examples and test questions were motivated by his real world experience. While this was very interesting at the same time it brought another level of complexity. One example was that we were learning about elements by mmol of substance and had to calculate how much of the input substances we needed to end up with the needed amount of end product. (My explanation might be of because this is some time ago!) Here we were not asked how many liters or kg of stuff we needed but always worked in metric tons or cubic meters. These uncommon volumes made it harder to develop an intuition about the results to quickly understand if a result was reasonable. So many of the surrounding elements that came from the real world made it harder to concentrate on the problem core.
It's the weird units. Students don't like weird units.
I remember I once, many years ago now, had a chemistry professor give temperatures in Fahrenheit for a thermodynamics problem, which to solve needed absolute temperatures in Kelvin. On a final exam. The class was not happy! (I didn't care, I both know the conversion and have a calculator that can do it.) He just wrote a table on the board with five entries: the boiling point of water in °F and °C, and the freezing point of water in all three systems.
Can you imagine that the students got even more upset at this? He eventually gave in and just did the conversion for everyone. I learned more than one thing that day.
Now I'm in industry and completely unfazed by this kind of thing. Sometimes shit's in Fahrenheit, that's just the way it goes, you just have to deal with it. Don't sweat the easy stuff!
The Stanford lecture by Robert Channing for one of the first courses in chemical engineering (ChE 101?) on youtube is fun for this.
He goes through how many of the units are defined and how it has had an effect on various projects throughout the years.
One of the best ones is about how the size of the space shuttles' tanks were constrained. They had to be able to fit on a train, so things had constraints relating to the distance between railroad tracks. Those railroad track sizes could be traced back to car axel sizes, and therefore previous horse-carriage axels. These carriages of course had the Romans before them, but all of these had axels defined by the width of two horses.
So ultimately the size constraints on the space shuttle arose from the distance between two horses asses.
Kind of fun.
So strange, I remember the Fahrenheit (32, 212) and Celsius (0, 100) numbers, but the precise Kelvin number (which is hard-required for all the good physics equations I've forgotten), that is how much lower than 0C absolute zero is, I only vaguely remember as 272 something. However that's just a well known constant. Very reasonable to include it in the reference dataset.
Well, okay, they changed Kelvin and Celsius at the same time, so that 273.15/273.16 are preserved, with Celsius based on Kelvin instead of the other way round.
But when you're dealing with the freezing point of water and the old version of Celsius for simplicity, then those numbers aren't as correct as they used to be.
On the other hand, gradually increasing the complexity and level of detail (including distraction with irrelevant details and like taking away your intuition crutches) is a great way to start learning to apply your knowledge in a more sophisticated way.
Mol as a chemical unit of measure is part of the first year chemical curriculum at Bavarian Gymnasiums (in three tier school system, those are the ones paving the paths to university). I remember I hated calculating in mol, but then we also expose students to all kinds of units of measure in physics.
>Real world examples tend to have a huge amount of unpleasant details which hinder transfer of the underlying concepts.
This. I hate all these blogs, where they are teaching, for example, Django , and start by asking us to setup Postgres/Mysql "because it is a real world database".
And I just quit, as I dont want to deal with the hassle of setting up Postgres, or spend hours setting up Docker on my personal Mac.
And many blogs for beginners will spend 20 minutes teaching them to setup Git "because it is good for you". And I know many beginners just get overwhelmed and quit
Standard Reddit/HN condescending response "But everyone should know git/mysql etc! Are you not a REAL engineer?"
There's a parallel here that I've seen with new developers. Universities and bootcamps tend to focus on single journeys through software - "when the user does X, Y, and Z display this result". Then the dev comes to the horrible Real World where users do "X, X, X" or "Z, Y, X" or "X, Y, Volkswagon, Potato, Z" and they argue that The User Is Wrong, because they've only been taught about the happy path where users do what you thought they should do.
I'm not suggesting that compsci teaching should change, but that there shouldn't be too much expectation that the theory taught to students probably should reflect the real world. The real world is too noisy. It'd be impossible to learn anything. Leave those lessons to experience.
Grossly off-topic, but your "Volkswagon, Potato" reminded me of Borges' riff on taxonomy[0]. This is probably exemplary of the kind of rabbit hole one can get lost in if attempting the "real world" application during the learning of difficult concepts. Best be introduced in a sterile environment, and leave it to the workplace to destroy one's worldview in order to for it to be rebuilt according to the reality of the local context.
The list divides all animals into 14 categories:
Those belonging to the Emperor
Embalmed ones
Trained ones
Suckling pigs
Mermaids (or sirens)
Fabled ones
Stray dogs
Those included in this classification
Those that tremble as if they were mad (this one's my favourite)
The number of categories reminds me of this footnote in another of his stories: "The original says fourteen, but there is ample reason to infer that, as used by Asterion, this numeral stands for infinite."
I've developed teaching modules (for real-world stuff; not academia).
It's a huge amount of work, and needs to last a long time, because changing it is a bear.
Also, It. Cannot. Be. Wrong. Very often, the students I'm training are smarter and more experienced than I am. This tiny little corner of things is the only place that I have anything to tell them.
This means that keeping examples as small as possible, is to my advantage.
I usually consider any class I take, or give, as a "starting point." All I do, is plant the seed.
I think teaching good techniques and heuristics is more important than teaching rote.
You (almost) never have to do pushups in RL, but you do them in a gym.
Examples and exercises in textbooks are for _conceptual learning_.
They have to be simple - and thus unrealistic.
As you can see, I have no overarching theory here; it just seems like a topic worth thinking about.
Pulling this quote in because I think it is important. The post is a signal amplification of something worth talking about. Not a call to tear down some institute of textbooks.
On the topic called out, though. I'm sympathetic. I recall in grade school a classmate missing the question "without air resistance, what happens to a piece of paper you throw out the window of a moving car?" To me, it was somewhat clear that the "without air resistence" part was important, but my classmate missed it. Others ridiculed them for missing the point, but the more interesting question, to me, was what caused something thrown out to fall behind the car, and how did that relate to the question? That is, on hearing the wrong answer, I was more interested on following up with "and why is that?" Not jumping to "stupid! That is air resistance!"
How do you pull this to interesting topics, though? Programming, in particular, is interesting in that moving to "first principals" is stupid hard for anything graphical. Unless you are wanting to build an engine, you are far more productive using an existing environment. And, basic environments are much harder to force people into today; compared to when the computer booted to a prompt and didn't really store anything for when it was turned off.
Then there is modelling and general ML. Turns out, simple models still dominate all but the most advanced engineering today. And there is no real reason to think that will change. Sure, with enough data, I think deep learning is borderline magic. Turns out, even places that have terabytes of data often have far less relevant data. I'm convinced there is a Nyquist/sampling relation out there for most data. But... I have no idea what that would be. So, we are stuck with simplistic housing price models for the time being. All the while, real estate is basically "whatever sold in the neighborhood recently is what you can expect."
I'm pretty sure the next step here will be to build algorithms that pull in colorized 3D data of comparable resolution to what Google Maps has today. Then the algorithm should be able to classify stuff like "this is a nice garden with sunlight all evening", "this has a nice view from the living room", "this one has windows facing the neighbour's windows" etc.
I recently pulled down Google Maps data for my neighborhood into Blender (using Chrome+RenderDoc and a plugin for GMaps import). To a human, the resulting colorized 3D model is more than enough to understand most there is to know about the exterior of a property.
I'm pretty sure the largest factor to consider is the buying power of people in the city. Just look at the Seattle market, where houses often goo for +30% of asking. The houses are definitely not magic compared to other similar cities nearby.
The world is a messy place, having simple examples in a "perfect" scenario does help understanding basic concepts, which then can be applied in more complex scenarios as you build upon that knowledge. It is however important (in my opinion) to explain the drawbacks and benefits of the methodology used early on.
To this day it has always been my biggest beef that textbooks don't reflect reality.
If we look back to our school days in maths classes with Sir getting all excited about teaching the class how to do y = 2x - 2, solve for x.
All your average kid does is quite rightly ask themselves "What's the **ing point, I'll never use this junk in real life".
Then decades later, people like me occasionally find myself (trying to) understand interesting sounding papers on machine learning, but the maths just flies right over my head.
I'm all for a practical approach to teaching. Its more interesting to learn and as a result it leaves you with a higher chance of the theory sticking in the student's head.
Its better than the alternative approach of just whacking students over the head with dry theory books in the hope that some of it sticks.
The basketball excitedly coach asks the team to do 50 pushups every training session.
All your average player does is quite rightly ask themselves "What's the *ing point, I'll never do a pushup in a real game".
The purpose of mathematics is to train your mental muscles in a very specific way. Irrespective of whether you use those particular calculations in your later life, doing mathematics generally makes you a better quantitative and formal reasoner. That's the point. And I think a lot of students who are good at mathematics intuitively get this idea. And therefore are excited about studying just math for the sake of math.
Don't you think it would be much easier to teach e.g. astrology or medieval scholastics if you want to produce a stream of mediocre workers that support power? Dictatorships relied on those kind of methods to keep the people in line.
We teach math just in case someone gets it, not to make everybody understand it deeply. And we don't only teach maths, but also languages, geography, biology, physics and all the rest.
The system is far from perfect, but there are not enough people to teach everybody well. Yet here we are: people are fairly well educated, we can create mRNA vaccins, build tiny supercomputers, and huge vertically landing rockets, and today we read about the relation between one-way functions and Kolgomorov complexity. I think the situation is not that bleak, although the golden age of education might indeed be behind us.
I'm not sure what your beef is. If you run a 10 minute mile in gym class, you shouldn't expect to be able to show up to the city marathon and finish. Getting to the level of running marathons, or reading complicated mathematics papers and understanding them, requires years of training and preparation, and an ability to place results in context which requires you having read and understood most of the existing context already. And it all starts with running that stupid 7 minute mile in gym class and understanding how to solve algebraic formulas quickly. Just because you skipped the intermediary training, doesn't mean the basics are junk because you can't grasp the expert level content.
Part of the problem is that the entire point of textbook problems is to not be representative. Failing all else, even all the also-excellent points described by other people in other comments, they have to be pedagogical. The vast bulk of almost all jobs, tasks, problems, etc. are highly stereotyped, and trying to give some sort of "uniformly random" sample of some task set would produce problems that are simultaneously 1. too boring to be worth using to teach with and 2. too complicated to be useful. If that seems paradoxical, the resolution is that it would be generally the same complication, over and over and over, from whatever problem set you're drawing from.
We have to present simplified problems, and in order to get a sampling across many possible complications that our students could be going out into the world and seeing (because while all of them are likely to end up solving stereotyped problems in some domain, we don't have any idea which ones they are yet!), we need to sample things in an unrealistic manner. It is an unsolvable problem.
I still have my opinions about how education is done; I think one of the most fundamental errors it makes that is not talked about is that it is virtually impossible to provide a solution to someone who doesn't have the problem in the first place, and our entire system is top-to-bottom structured around providing solutions. This, I think, is an even more fundamental view of the disconnect underlying the issue of textbook problems not being representative... "textbook problems" are a misnomer, really, because they aren't problems. I don't care if Sally does or does not get her 1/7th of an apple, and the technique of connecting a grade to whether or not I answer correctly is really quite clumsy and of dubious effectiveness. But it would take a top-to-bottom rethink of the curriculum of the sort I've never really seen anyone try. I've seen people peck around the edges and I've seen people throw the baby out with the bathwater but a problem-first-centric education would be such a radical departure that I don't think people can even think it.
They probably don't have to be!! Training for actual warfare doesn't mean you have to be killed during that training!! But I am with the opinion that the more you're exposed to real world stuff and the more "battle-hardened" you are, the better!
I think that 'real life' examples are often worse.
Learners can get too caught up on adventitious details in the example like the wording or certain irrelevant details.
If the example is a real life example they are familiar with it could lead them away from the essential features the example is trying to reason from.
It's a common trope in movies to have a sassy kid show up the teacher by pointing out how artificial their example is and then proceeding to solve the problem realistically most of the time involving street smarts.
While this can be amusing this is also missing the point. The example is there as a learning aid to learn a particular concept.
In regards to Bayes Theorem in the XKCD comic being used in the 'real world'...
I haven't ever really learned about the theorem except in passing through some articles and a brief mention in highschool once.
Even so, I still ended up basically using Bayes Theorem to successfully do something IRL. What was it?
Hunting ghosts in a game called phasmophobia. Some friends and myself were playing it on discord and were having a hard time figuring out which ghost it was we were supposed to be hunting. That is, until I started trying to figure out the negatives before figuring out the positives. The others were curious as to what I was doing, as it seemed to be working finally, and so I told them; "I'm fairly certain this game is using a rudimentary form of Bayes theorem, which is how we are finally getting these correct."
And correct we were, time and time again; despite never having gotten all the respective 'positive' clues.
When you're teaching something new, you want to be able to isolate that concept/technique and focus in on it. A simplified example, or a question with strict parameters, both allow the student(s) to concentrate on the key idea.
If you want to teach someone about SELECT in SQL, for example, it's useful to abstract away the database setup for that particular lesson. It's also useful to use a simplified database concerned with familiar entities, so that SELECT remains the focus rather than one new element of many.
Of course, these simplified examples shouldn't be used in isolation. Instead, you should have a number of them, eaching illustrating/assessing some small point or idea. Once the students have absorbed those ideas, then you start combining the initial building blocks into more complex ideas, just as you'd take a tiered approach when testing software; start with unit tests, then build up.
Effective education moves in steps.