Creating our program

You might be wondering when we are supposed to actually start writing some Swift code; it is right now. Let's go straight to the code by typing the following code in the editor of our playground:

print("Hello World")

Tip

All related source code for this chapter can be found here: https://github.com/swift-book-projects/swift-3-programming-for-kids/tree/master/Chapter-3

After writing this code in the editor, the playground should run. You can see this by checking whether the play button at the bottom changes to a stop button, or whether the status at the top shows Running instead of Ready. When the playground is done running, you should be able to see the result of our code in the right column. It should be as shown:

"Hello World\n" ...

Get Swift iOS Programming for Kids now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.