Create Task: Abstraction: Function with only a single instruction

If a student creates a function that only has one single line of instruction, so for example:
function changeScore(){
total = total + 1;

Would this be considered a student-developed abstraction, as well as something that manages complexity? The way many of my students end up describing their reasoning for it being an abstraction is something along the lines of, “I can call my function, rather than writing out all of the code within it each time.” Since this is only one line of code, it doesn’t seem like it would count as an abstraction, nor would that reasoning count as managing complexity.

I could see if they described the complexity of their code and stated that they were using the function to help as an organizational strategy, but using it as stated above doesn’t seem point-worthy (for either lines 7 or 8) to me.

Can someone weigh in on their opinion?


I think it can get a point for being an abstraction but I think it would be hard to justify that it manages complexity. It’s hard to argue that you are reducing complexity by replacing one line of code with another. If the function not only incremented the score but also changed the score on the screen then I think you can say that would reduce complexity of the code.