The Code Commandments: Best Practices for Objective-C Coding (updated for ARC)

Updated April 26, 2012 for ARC

Preface

I don’t normally post highly technical stuff to my blog, but here’s an exception that I hope will benefit the Mac and iOS (iPhone & iPad) developer community. So if you’re not part of that, feel free to skip it.

Introduction

This article is a cumulative list of the most commonly-violated best practices for Objective-C coders that I’ve witnessed in my many years of experience with the language. I call them “commandments” because there are many good reasons to observe them and few, if any valid reasons not to. However, when I show these practices to other developers, they frequently raise one big objection…

Continue reading

Comments? Send a tweet to @ironwolf or use the response form.
I can’t respond to everything, but I do read everything!

Learning to Program with Teaching Languages

This is a short revue of some of the teaching languages I have been impressed by. If you’re looking to cut your teeth on programming, these are all good choices, they all have easy step-by-step tutorials, they are all available for a variety of platforms including Mac, Windows, and Linux, and they are all free!

Logo

Logo is the Wise Old One of teaching languages. It is also the language that introduced so many of us to geometric concepts via its innovative use of turtle graphics. Here is a free Logo implementation for Mac OS X. Here is a Logo design gallery.

Alice

Alice is an object-oriented programming language that also teaches concepts of 3-D programming and includes built-in tutorials. Here is the Alice home page.

Squeak

Squeak is an implementation of the venerable Smalltalk programming language— perhaps the first true object-oriented language. Here is the Squeak home page. An offshoot of the Squeak project is Squeak Etoys, which is a powerful and dynamic learning environment.

Scratch

Scratch is also based on Squeak, and provides a dynamic programming environment that encourages a community of sharing code among its users. The Scratch home page.

Context Free

Context Free is a program that generates images from written instructions called a grammar. The program follows the instructions in a few seconds to create images that can contain millions of shapes. There is a gallery with thousands of art pieces and their source code.

Processing

Processing is an open source programming language and environment for people who want to program images, animation, and interactions. It is used by students, artists, designers, researchers, and hobbyists for learning, prototyping, and production. It is created to teach fundamentals of computer programming within a visual context and to serve as a software sketchbook and professional production tool. The Processing home page.

Wiring

Wiring is an open source programming environment for exploring the electronic arts, tangible media, teaching and learning computer programming and prototyping with electronics. Wiring is based on Processing. The Wiring home page.

Arduino

Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use hardware and software. It’s intended for artists, designers, hobbyists, and anyone interested in creating interactive objects or environments. The Arduino programming language is based on Wiring. The Arduino home page.

Comments? Send a tweet to @ironwolf or use the response form.
I can’t respond to everything, but I do read everything!