Learning & Teaching Code Style & Appreciation

Yesterday in an informal COSC208 (C and C++ programming) lecture at the University of Canterbury, discussion broke out on how to teach and learn coding Style. Here are my 2 cents;

I believe it's not possible to effectively teach & learn Style with single-developer programs that have a clearly limited life span -- such as all code written for COSC208 and most undergraduate university papers. Once the paper has finished and the grade has been determined, who is going to maintain the student's code? Who is going to read your code? No one. So why would the author/programmer/student bother to make it easy to read or maintain, or care for Style? They would not -- except if the prof mandates it. But as pointed out yesterday, that is very resource-consuming and fails to teach an appreciation for Style.

How to get the most value out of your programmer

This article about the psychology of programmers hits the nail on the head. Finding it difficult and even impossible to get 'into the flow', was one of the sources of frustration in my recent employment that lead me to resigning.

Now I work virtually for CivicActions and I can create my own space and time to get in the flow and do the fun interesting (and billable) work.

Quotient data type

I'm a first year computer science student. The programming paper I'm doing at Massey University is (unfortunately) in C#. And that s the language I'll use in the following examples.
From what I've understood about basic data types; an integer is a whole number, with no fraction or decimal value, and doubles and floats are numbers with a decimal value. This works well for most common calculations, but sometimes it is more accurate or convenient to store a value as a fraction; a quotient of two integers.
Syndicate content