My philosophy on teaching computer programming stems from my first college computer science course, "The Structure and Interpretation of Computer Programs". It was taught in Scheme, a language that is mainly for learning programming and generally not for
software development. It wasn't the language that mattered, but rather the concepts of programming that were taught through the language. That is how I thought to come up with the "ADCs of Programming" as a way to introduce students to the concepts of programming
"A" is for actions. What tasks can the programming language perform? Most can do arithmetic, but the set of actions varies by programming language. "D" is for data. Every programming language has a way of representing data, from literal values to variables,
because actions need to work with data. "C" is for choices. Without the ability to choose what actions to do or what data to use, programs would...
Teaching courses at the college level has taught me that one teaching style does not fit all students. In a college course environment, however, an instructor cannot always stop in the middle of a class to re-frame a lesson to suit the students who just
aren't getting the topic. With one-on-one tutoring or even small group tutoring, a tutor has the opportunity to present a topic, check if the student(s) "get it", and if not, try a different approach to the topic on the spot. Tutoring means not going strictly
by a syllabus but instead meeting the needs of the student, varying the material and teaching approach as appropriate.
Like many other subjects, computer programming invites a variety of approaches to learning. It can be formal, hands-on, puzzle solving, problem solving, or exploratory. Different topics in programming are best suited to particular approaches. For instance,
loops are best taught hands-on with plenty of examples to understand their mechanics...
Why would failure ever be a good thing? Well, in computer programming, failure can mean that you have done a good job testing your code and you have found a bug. Finding a bug during testing means that you can fix your bug before you submit your project
or assignment to your boss or your teacher. In the process of fixing the bug, you might realize how to improve other parts of the code as well. Without thorough testing, with a possible failure or two along the way, you cannot be confident that your code will
do what it is supposed to do.
So, how do you go about testing? One way is to think of as many examples of possible input data as you can. Good input, bad input, simple input, and complicated input should all be tried. Keep a list or a file of the examples so that you can try your code
on the examples each time you change your code. Another way is to enlist the help of co-workers or friends to try to "break" your code. You can never completely predict what...