An increasing number of educators believe coding is a fundamental literacy for the 21st century. The solution that ruffles the least feathers seems to be a one-semester "Intro to Programming" course, a one-shot inoculation in computer science in which nonprogrammers grit their teeth through a cramped syllabus that rushes through variables, loops, and functions without regard for why they are relevant. In our experience, such courses can have the opposite effect of their intention--making creative students who'd rather be penning song lyrics or designing a logo less likely to identify themselves as programmers, or even people remotely interested in programming.
Following a curricular review begun in 2011, the University of Maine's New Media Department chose to encourage technical depth across all its students by adopting a baseline programming language, a department-wide standard for technical development that appears in multiple courses. The department introduces this language over a three-semester arc of foundation courses, emulating the course-by-course integration pioneered by "Writing across the Curriculum" programs. Skills learned in this arc are then reinforced by lessons in upper-level courses that apply those skills to subjects like digital storytelling, mobile applications, and physical computing.
But what language to teach?
In 2012-13 we chose for our baseline the suite of languages known as HTML5, as they apply to a number of needs across multiple sequences, including support for text, video, and graphics as well as the ability to deploy on the Web and mobile devices. By no means should a baseline language preclude training in other languages such as objective-C, Flash, or Max/MSP. Rather, consistently using one technology will provide experience that can be translated to other technologies later.
In current parlance, HTML5 is a catchall term including the latest standard for Hypertext Markup Language as well as Cascading Stylesheets (CSS) and JavaScript. Although best known for its central role in creating Web pages, this combination of languages has increasingly been applied to everything from Photoshop to ebooks to iPads.
To make their choice, the faculty researched modern cross-platform programming languages and ranked them according to features and platform applicability. Green indicates full compliance, Yellow partial, Red no compliance.
Language | Features | Platforms | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Easy learning curve? | Scriptable? | Native print output? | Native media output? | Store data? | Open standard? | Adobe | Web | Flash | OSX | Windows | Linux | iOS (iPad etc.) | Android | Other platforms | ||
HTML5 / CSS / JavaScript | Yes | Yes | Native support for audio, video | Web and DOM Storage | Yes | Photoshop, Illustrator, Dreamweaver, InDesign | Native language of all browsers; AJAX; JSON; bookmarklets; Greasemonkey; browser extensions (Safari, Firefox) | as ActionScript | Dashboard Widgets, Rhino, or OSA | Yahoo Widgets, Microsoft and Google Gadgets | Widgets, GNOME shell | as Web App or via PhoneGap | as Web App or via SL4A | Gaming/3D (Unity, Sphere, Re-Animator, DX Studio, VRML); audio (Max/MSP); productivity (OpenOffice, Google Docs) | ||
PHP | Yes | Yes | No | Yes | Yes | No | Yes (with HTML) | No | Yes | Yes | Yes | No | No | TBD | ||
Ruby | Yes | Yes | No | Yes | Yes | No | Yes (with HTML) | No | Yes | Yes | Yes | No | No | TBD | ||
Python | Yes | Yes | No | Yes | Yes | No | Yes (with HTML) | No | Yes | Yes | Yes | No | via SL4A | TBD | ||
Processing | Yes | No | TBD | Yes | TBD | Yes | No | via JavaScript interpreter | No | Yes | Yes | Yes | No | via Mobile Processing | TBD | |
Max/MSP | Yes | No | TBD | Yes | TBD | Yes | No | No | No | Yes | Yes | Yes | No | No | TBD | |
Java | No | No | No | No | Yes | Yes | No | via Applets | No | Yes | Yes | Yes | TBD | Native support | TBD | |
C | No | No | No | No | Yes | Yes | No | No | No | Yes | Yes | Yes | TBD | TBD | Gaming (Unity) | |
C++ | No | No | No | No | Yes | Yes | No | No | No | Yes | Yes | Yes | TBD | TBD | TBD | |
C# | No | No | No | No | Yes | Yes | No | No | No | Yes | Yes | Yes | TBD | TBD | TBD | |
Objective-C | No | No | No | No | Yes | Yes | No | No | No | Native support | No | via GNU runtime | Native support | No | TBD |
As this chart summarizes, HTML5 boasts clear advantages in easy learning curve and broad compatibility across diverse platforms, including some that are likely to appeal to the less technical student.
Using HTML5, a writer can edit ebooks. A designer can supercharge Photoshop or Illustrator, using JavaScript loops and random processes to generate imagery that would be impossibly time-intensive to create by hand. A gamer can build virtual worlds and gameplay with Unity; a filmmaker can make an interactive video with Popcorn.js; an entrepreneur with an idea for a mobile app can go from assignment to App Store in five months thanks to PhoneGap.
And all of them can use HTML5 to build all the moving parts of today's Web, from static pages to dynamic interfaces, from AJAX to JSON, from bookmarklets to browser extensions.
Perhaps most importantly, HTML5 is inherently an open language, making it easy for peers to learn from each other in collaborative environments like The Pool.
With this research in mind, we chose to teach our baseline language of HTML5 according the following approach:
The target demographic is students who may be more facile in expressive media than programming skill or abstract thinking. To make theory concrete, the lesson plans alternate between hands-on practice in the actual coding environment (a laptop) and more Big Picture lessons designed to enhance conceptual understanding.
To overcome the "I'm not a programmer" mentality, we propose to build confidence through incremental study and mastery of syntax. This learning will be reinforced by re-examining the same core language at higher levels and in various environments as a student progresses through the major.
We'll start with the easiest elements of HTML markup and progress through the slightly more abstract design elements of CSS. The upper level class will examine the interactive potential of JavaScript, culminating with an examination of current JavaScript frameworks such as jQuery. Advanced students may explore JavaScript's implementation of sophisticated concepts such as namespaces, prototypal inheritance, and closure.
To eliminate the crutches students often rely on, we will stress hand-coding over authorware (Photoshop slices) or cut-and-paste code (DynamicDrive).
Early on, concentrate on easy-to-make projects that enable a variety of creative expression. More advanced classes and students may examine complex or optimized code, but always at the service of an application or design problem that is central to a class or sequence.
We won't teach little-used or deprecated features of the standard. We won't introduce slick features of the HTML5 specification until they are adopted by more than one major browser.
While making room for individual languages for various specialties, we will not confine programming to a particular class or track, but integrate the application of JavaScript into sequence courses in design, documentary, interaction, narrative, and networks.
It's easier for students to teach each other and collaborate with a baseline language as common denominator. Interactive screencasts and badges designed by students themselves can help foster more abstract learning outside of the classroom, leaving class time for bottom-up project development.