Auglets - Definition
Refactoring is defined as improving the internal structure of a program without
altering its external behavior [1].
Improving the internal structure of a program may involve eliminating redundancy or
improving efficiency, readability or modifiability of a program.
Auglets are software tutors that help students learn to refactor code:
- Problems are presented as a problem specification along with a program written to solve it.
- User interface consists of actions such as
deletion, duplication, relocation and token-wise editing of a line of code.
Students are not allowed to edit the code free-hand, emphasizing that
refactoring is not so much rewriting code as rearranging code.
- Feedback is provided after each action as well as after the student has
submitted an incorrect solution. The correct solution is displayed alongside
the problem with the differences between the two highlighted.
-
Students can take as many actions as necessary, but cannot
move on to the next problem until they have refactored the current problem correctly.
So, proficiency is measured not in terms of the correctness of the student's solution,
but in terms of the number of actions used by the student to solve a problem: the greater the number
of actions, the less likely that the student has mastered the material.
References
-
Martin Fowler, Refactoring: Improving the Design of Existing Code, 2nd edition, 2019, Addison Wesley.