I am an assistant professor for a course on audio signal processing (for engineers) and I often write snippets of code to try to help the students follow the material. In addition, I get to lecture (1) one session of the course.
I have a lot of code I wrote over the last couple of years for this particular session but I realized my comments on it are not consistent at all and I have not found any sort of standards or guidelines for pedagogically appropriated commenting style.
Should I comment this code like I normally do with any code?
I usually add a header comment explaining which course the code was written for and something about what it is showing. But I also tend to comment the code with some trivialities in order to state somethings that I think would be obvious to developers but not to engineering students.