I have for some time been pondering two problems. One is to
identify the fourth R in Reading, wRiting, aRithmetic,
and pRogramming. There are many contenders for the kids'
first step. I believe the English government has chosen Phyton as a
first language. Scratch has a certain popularity, there are many
others. My concern is "what comes next"? I want the kid to gradually
build a mental model of what computing is all about. Learn a little,
do a little, lean more, do more, etc. up do old age. This goes much
deeper than any programming language. It's a bit as learning to
read. Personally, I "broke the reading code"at an early age. Since
then, I have been learning more and more. What I read today would
have been incomprehensible to me 75 years ago. But my basic
mental model of what reading is all about has remained unchanged. I
have never had to unlearn anything.
I suggest that true object orientation (not class orientation) can
form the foundation for the human mental model of computing.
Internalize it and live with it forever.
-------------------------------------
The other problem is to find a better example for DCI presentations.
It should
Be executable and have a cool demo effect.
Its domain model should be obvious from the demo.
It should have very few and very simple Data classes.
It should have a Context that is clearly and obviously
separate from the Data.
It should scale to any number of Contexts (use cases)
without changing the Data classes.
----------------------------------------- Last night I got an idea for an example: A waltzing couple. (See
the attached for a picture and Wikipedia for a movie of the use
case).
The program needs one simple class for a moveable shape and a DCI
Context for each dance (waltz, foxtrot, tango, ... for two role,
polonaise for more.) The example will clearly demonstrate the
wisdom in separating what the system IS from what the system DOES
since the simple Shape class would be overloaded with instance
methods for all dances.