Subscribe / Unsubscribe Enewsletters | Login | Register

Pencil Banner

Learn code with Swift Playgrounds

Lucy Hattersley | July 4, 2016
Apple's new Swift Playgrounds app aims to teach kids how to code and create apps

Swift Playgrounds is a new app revealed by Apple at WWDC 2016. Aimed principally at children, Swift Playgrounds is designed to make learning to code easier, and more fun.

Set for release alongside iOS 10 (due in Autumn), Swift Playgrounds will be a standalone app that can be downloaded from the App Store.

In Swift Playgrounds, Apple says: "Technology has a language. It's called code. And we believe coding is an essential skill. Learning to code teaches you how to solve problems and work together in creative ways. And it helps you build apps that bring your ideas to life. We think everyone should have the opportunity to create something that can change the world. So we've designed a new approach to coding that lets anyone learn, write, and teach it."

How to use Swift Playgrounds: what is a playground?

How to use Swift Playgrounds on iPad

Developers will already be familiar with the term Playground as this is a feature found inside Xcode (the professional development environment used to create apps) Like Playground in Xcode, Swift Playgrounds is a place where people can experiment with code.

The Swift Playgrounds apps for iPad goes far beyond using an Xcode Playground. As well as being an experimental area for trying out code, it features interactive tutorials where you control a character in a 3D world using code.

In Swift Playgrounds, you'll control a character called "Byte," a giant orange cartoon character with a single eye and yellow trunks (he reminds us of Earl, from the cult 1990's videogame ToeJam & Earl).

You issue commands to Byte, such as moveForward() and turnLeft(). Implementing these commands, along with loop and conditionals, enables you to guide Byte around each level.

Beyond the tutorials, you will also be able to use Swift Playgrounds to build your simple programs. These can interact with iPad technology, such as the built-in camera, microphone, touch display and accelerometer.

We're not sure how advanced the features available in Swift Playgrounds will let you go. But it could be possible to build simple games in Swift Playgrounds.

Interestingly, you can take an app built in Swift Playgrounds and export it to Xcode. So Swift Playgrounds could serve as a digital sketchpad for Swift programmers, as well as a teaching aid.

How can I learn to use Swift Playgrounds?

Learn to code in Swift on iPad

We don't expect Swift Playgrounds to be a difficult app to use.

It should be simple enough for parents, and teachers, to use Swift Playgrounds, and Apple has created a guide, also called "Swift Playgrounds."

 

1  2  Next Page 

Sign up for CIO Asia eNewsletters.