How can I deal with the cargo-cult programming attitude?
- by Aivar
I have some computer science students in a compulsory introductory programming course who see programming language as a set of magic spells, which must be cast in order to achieve some effect (instead of seeing it as a flexible medium for expressing their idea of solution).
They tend to copy-paste code from previous, similar-looking assignments without considering the essence of the problem.
Can anyone recommend some exercises or analogies to make these students more confident that they can, and should, understand the structure and meaning of each piece of code they write?