General Development Archive

21 nested callbacks

"Programming is hard. Don't ever feel bad because you aren't as good at 'just googling it' as the person next to you. Don't ever let hackathon snobs talk you out of creating the next Twitter for cats or Yelp for public washrooms. Even the dumbest ideas (like trying to make animated polygons disappear and reappear) will help you improve as a programmer. Learning to program is largely about learning to learn - and the best way to learn is to do." For some reason, I love this short story.

Duke Nukem 3D code review

"Since I left my job at Amazon I have spent a lot of time reading great source code. Having exhausted the insanely good idSoftware pool, the next thing to read was one of the greatest game of all time: Duke Nukem 3D and the engine powering it named 'Build'. It turned out to be a difficult experience: The engine delivered great value and ranked high in terms of speed, stability and memory consumption but my enthousiasm met a source code controversial in terms of organization, best practices and comments/documentation. This reading session taught me a lot about code legacy and what helps a software live long." Hail to the king, baby.

The exceptional beauty of Doom 3’s source code

"I was really excited to write this article, because it gave me an excuse to really think about what beautiful code is. I still don't think I know, and maybe it's entirely subjective. I do think the two biggest things, for me at least, are stylistic indenting and maximum const-ness. A lot of the stylistic choices are definitely my personal preferences, and I'm sure other programmers will have different opinions. I think the choice of what style to use is up to whoever has to read and write the code, but I certainly think it's something worth thinking about. I would suggest everyone look at the Doom 3 source code because I think it exemplifies beautiful code, as a complete package: from system design down to how to tab space the characters." John Carmack himself replies in the comments.

The rise and fall of programming languages in 2012

"Programming languages are living phenomena: They're born, the lucky ones that don't die in infancy live sometimes long, fruitful lives, and then inevitably enter a period of decline. Unlike real life, the decline can last many, many years as the presence of large legacy codebases means practiced hands must tend the code for decades. The more popular the language once was, the longer this period of decline will be."

The unreasonable effectiveness of C

"For years I've tried my damnedest to get away from C. Too simple, too many details to manage, too old and crufty, too low level. I've had intense and torrid love affairs with Java, C++, and Erlang. I've built things I'm proud of with all of them, and yet each has broken my heart. They've made promises they couldn't keep, created cultures that focus on the wrong things, and made devastating tradeoffs that eventually make you suffer painfully. And I keep crawling back to C."

Celebrating 25 years of Perl

Doesn't matter which OS you're running, somewhere in there, your system depends on Perl to get stuff done. Perl turned 25 years old on December 19th. Though venerable old version 5 remains the most popular, many have moved onto Perl 6, which intentionally broke compatibility and still isn't officially 'production ready.' I can't imagine administering a system without Perl though, so tonight I'm raising a glass of champagne in the direction of founder and creator Larry Wall.

An introduction to writing for computers

"Computers are ubiquitous in modern life. They offer us portals to information and entertainment, and they handle the complex tasks needed to keep many facets of modern society running smoothly. Chances are, there is not a single person in Ars' readership whose day-to-day existence doesn't rely on computers in one manner or another. Despite this, very few people know how computers actually do the things that they do. How does one go from what is really nothing more than a collection - a very large collection, mind you - of switches to the things we see powering the modern world?"

X86/ARM emulator

"This article offers something different. A Visual Studio Express based solution, written using C++ and assembler, that allows the user to write and execute X86, X86/64 and ARM assembler line by line as easily as using a text editor. As code is only emulated, errors are trapped and reported within the program without any wider impact."

Developing a basic operating system on the Raspberry Pi

"This website is here to guide you through the process of developing very basic operating systems on the Raspberry Pi! This website is aimed at people aged 16 and upwards, although younger readers may still find some of it accessible, particularly with assistance. More lessons may be added to this course in time." From the Computer Laboratory, University of Cambridge, one of the institutions behind the Raspberry Pi. Amazing resource.

Interview: Brian Kernighan

"Originally published in 1978 and updated in 1988, The C Programming Language is considered a 'must-read' classic by most programmers and is generally known simply as 'K&R'. To mark the publication of an ebook version of the 1988 second edition, we interviewed coauthor Brian Kernighan about the C programming language, the book, and future trends." And an Oxford comma to boot. The way it should be.

TypeScript: Microsoft’s replacement for JavaScript

"Everyone seems to have a replacement for JavaScript - Google even has two. Now Microsoft has revealed that Anders Hejlsberg has been working on a replacement and it has released a preview of TypeScript. TypeScript is open source - Apache 2.0 license - and a superset of JavaScript. As you would expect from a Hejlsberg language it incorporates type checking, interfaces and lots of syntactic sugar."

The programmers before us were better

"When I started writing programs in the late 80s it was pretty primitive and required a lot of study and skill. I was a young kid doing this stuff, the adults at that time had it even worse and some of them did start in the punch card era. This was back when programmers really had to earn their keep, and us newer generations are losing appreciation for that. A generation or two ago they may have been been better coders than us. More importantly they were better craftsmen, and we need to think about that." I'm no programmer, but I do understand that the current crop of programmers could learn a whole lot from older generations. I'm not going to burn my fingers on if they were better programmers or not, but I do believe they have a far greater understanding of the actual workings of a computer. Does the average 'app developer' have any clue whatsoever about low-level code, let alone something like assembly?

Code better or code less?

"Having read this, one realization is that better code often means less code. I don't think about lines of code exactly, or something similarly stupid, but in terms of meaningful code. However, argument for less code isn't about making code as compact as possible, avoid redundancy, etc. The argument is about not writing code at all whenever reasonable or possible. Should we focus on deciding what should and what should not built instead of polishing our software development craft then? Yes and no. Yeah, I know. Exactly the kind of answer you expected, isn’t it? Anyway, you can't answer this question meaningfully without a context."

Developers, engineers, scientists

"I've been programming professionally for about 3 years at this point, and I've noticed some interesting patterns in other programmers I've worked with. One of the key differentiators among programmers is motivation. I'm not referring to an individual's passion to simply be successful in their career, but rather the type of work they want to pursue. The thing they want to do with computers every day, the types of problems they are interested in solving."