Programming productivity
Programming productivity
When designing the AI Framework and C* language subset, a lot of effort went into studying which programming languages had the highest programmer productivity, and why. Scripting languages were often recommended in general, and Python in particular for increased programmer productivity.
Python (and other scripting laguages) most important productivity factors
- higher level of abstraction (a line of code typically does more in a scripting language)
- less code/typing (easier to type, easier to read, easier to maintain and change)
- powerful built-in data types (strings, arrays, dictionary/hash etc)
- powerful standard library and third-party libraries ("batteries included")
- fast feedback cycle (interpreted, no compiling)
"The minimal finger typing and powerful data types work together to make your program small, and make you feel more productive. "
- Guido van Rossum, Python creator
Of course, programming language is only one of many factors determining programming productivity:
01 - Skill, talent, motivation (# 1)
02 - Language (C, C++, C#, Java, Lisp, Ruby, Haskell etc)
03 - Automatic Memory handling / Garbage collection (Java, C#, Script languages)
04 - Framework / Libraries (Java, .Net etc)
05 - Environment / Working conditions (workspace, hardware)
06 - IDE (Visual Assist, CodeReview), including help system
07 - Amount of typing - less typing, less code, less errors (verbosity)
08 - Data types (arrays, lists, maps, strings)
09 - Conventions gives less code (handle lower-level details for you - Ruby on Rails)
10 - Compilation vs. script (interpreted)
11 - Debugging / Tracing / Testing (find bugs, avoid bugs, easier testing)
"One finds terms such as 'software manufacturing', proposals to measure programmer productivity by the number of lines of code produced per month etc., although I have never seen the suggestion to measure composer productivity by the number of notes, monthly scribbled on his score!"
- E.W.Dijkstra
A different view is presented by Peter Hallam from Microsoft, who estimated how much time real developers spend on coding:
| New code | 5% |
| Modifying existing code | 25% |
| Understanding code | 70% |
As the most time is spent understanding code, code readability is very important. Less complexity and less code in general will increase readability, as you're able to grasp a larger portion of the code at once (and understand it faster).
This is why our motto is KISS - Keep It Simple, Stupid !
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it."
- Brian Kernighan (Stack Exchange discussion)
By writing as little code as possible, there is less to write, less to modify and less to understand (and less to fix).
By writing as easy code as possible, it is easier to write, easier to modify and easier to understand (and easier to fix).
The C* language and the AI Framework was designed to be as simple and easy as possible, in order to maximize programming productivity.
"We shall do a much better programming job, provided that we approach the task with a full appreciation of its tremendous difficulty, provided that we stick to modest and elegant programming languages, provided that we respect the intrinsic limitations of the human mind and approach the task as Very Humble Programmers."
- The Humble Programmer by Edsger W. Dijkstra (ACM Turing Lecture 1972)
External links
- Programming at Python speed
- It's not about lines of code
- Scripting: Higher-Level Programming for the 21st Century (J. Ousterhout, IEEE Computer, Vol. 31, No. 3, March 1998, pp. 23-30.)
- Java offers Increased Productivity
- Icon - very high level programming language