For instance and using once again Example 3, we may intuitively reason and anticipate that question a) could be considered simpler than b); because, for a prototypical student, identifiers and operators notions relate very well to variables and basic arithmetic operations
(up to the use of '~' in ML instead of a prefixed minus). But data-binding and control as well as sequential data-flow can be something new or not yet assimilated by such a student.

See the interesting experiments evidencing some misconceptions that novices might initially develop with respect to binding (variable assignment, [30]) 10 Thus, because part b) of the exercise aims at the basics of data-binding and dataflow and this task can be considered cognitively harder than part a), we might take that knowledge into account during the design phase and organize the interactions accordingly, maybe as two independent exercises.

Thus, from a pragmatic perspective, we believe complexity could be relevant in a practical situation where relatively many given exercises might need to be carefully adapted to fit in an e-Learning environment.

## 4.2.3 Dynamic Generation Of Exercises

So far, we have seen a static perspective of exercise generation as done in ActiveMath. This view corresponds to the (pre)authoring facility when it is performed manually. However, as described in [50], ActiveMath also provides a more powerful functionality to dynamically generate exercises using a domain oriented representation instead of a dialog-oriented one.

(In [50] the domain is symbolic differentiation calculus).

Because such a facility represents a challenging issue in our particular domain of interest, we come back to this issue later on in this work. At this point we just notice that specific domain reasoning rules for symbolic manipulation of small programs could be required in order to provide a similar capability as in calculus domain.

Just as a simple example, consider case b) of Example 3. In this case, and certainly depending on the intelligence of the exercise generation procedure, we might need rules for expressing data-flow related operations; just as differentiation rules are used in [50].

Finally, we want to mention that another similar approach to the automatic generation of exercises is described in [24].  They report deriving exercises directly from the domain model, which in that case is the Databases (DB) and SQL. They use a random-walk on the DB-Schema representation, exercises are in this case DB queries.

## 4.2.4 Domain Specific Reasoning Rules

As described in [50] the exercise module in ActiveMath allows dynamic the generation of exercises where interaction can be added dynamically based on the diagnosis of student answers to the exercise task. Central to this feature is a domain reasoner (DR) working on the exercise task. The domain reasoner behaves like a (rule-based) expert system that