iTunes

Opening the iTunes Store.If iTunes doesn't open, click the iTunes application icon in your Dock or on your Windows desktop.Progress Indicator
Opening the iBooks Store.If iBooks doesn't open, click the iBooks app in your Dock.Progress Indicator
iTunes

iTunes is the world's easiest way to organize and add to your digital media collection.

We are unable to find iTunes on your computer. To download from the iTunes Store, get iTunes now.

Already have iTunes? Click I Have iTunes to open it now.

I Have iTunes Free Download

Swift Coding Challenges

Hacking with Swift - Test your Swift. Challenge your friends. Prepare for coding interviews.

This book can be downloaded and read in iBooks on your Mac or iOS device.

Description

Swift Coding Challenges is an all-new book written from the ground up to put your Swift 4 skills to the test. I've written a variety of coding challenges that start off simple but slowly get harder, and it's down to you to solve them.

I outline each problem, provide you with sample input and output, add in some hints in case you hit problems, then provide a sample solution and explain how it works.

Give your coding brain the exercise it deserves!

Looking for a job?

If you're brushing up your skills in the hope of nailing a job interview, Swift Coding Challenges is for you. Never again fear the dreaded whiteboard tests: Swift Coding Challenges will help walk you through some of the most common problems that get thrown at you during interviews, so you'll be able to practice solutions and ensure you're ready.

The goal is to solve each challenge yourself, but I always provide hints if you need them, as well as complete solutions and explanations so you always learn something new.

Perfect for coding clubs and book groups

If you run a Swift meetup or book group, Swift Coding Challenges makes for ideal reading, encouraging discussion, team work, and solution engineering. The book is structured so that each problem is presented in isolation, so you can pick out particular challenges easily and work through them together.

Learn with solutions

Each challenge is problem presented to you as a simple requirement, just like you would get at a job interview. For example one of the easier ones is, “write a method that returns true if two strings contain the same characters in any order.” 

You're then given some example input and output, so you can write test cases. In this example, you'd be given something like "the strings 'abc' and 'cba' should return true, but 'dog' and 'cat' should return false."

And that's it: you need to write code to solve the challenge. If you get stuck, I provide hints that help point you in the right direction. Ideally you don't need these, but they can help if you struggle with particular problems.

Finally, every challenge comes with a complete solution, complete with explanation of how it works so you can compare your code against mine. So if you beat the challenge you can check to make sure your code was optimal, but even if you didn't manage to finish you'll still be able to learn and do better next time.

Test your skills

Every challenge is graded from easy to hard, then grouped into chapters such as Algorithms, Files, Lists, Strings, and more. This means you can focus your efforts wherever you think you're weakest, then start at the beginning to find your skill level.

The book comes with 64 challenges in total, including these:

- Given two strings, write a function that returns true if all letters are unique.
- Make a version of the min() method that returns the three smallest numbers in an array.
- Write an implementation of quicksort for arrays.
- Recreate the built-in map() method for collections.
- Write a function that returns the frequency of a word in an input file.
- Given a Tic-Tac-Toe board, write a function that returns true if either player has won the game.
- Write a function that accepts a binary tree and returns true if it's balanced.
- Given a string with no duplicate characters, write a function that returns an array containing all letter permutations.
- Write a function that accepts an integer array and returns its median value.
- Write a function that accepts a linked list that loops back to itself, and returns the item at the start of the loop.

And that's just a sample – the full book is packed with challenges at all difficulty levels, complete with hints and solutions. 

BONUS: You get 90 "Be the compiler" test questions that present you with source code and ask you to figure out what it does. Each answer comes with an explanation so you learn as you go, and the tests are split across three levels so there's something for everyone.

Give your coding brain the exercise it deserves!

Screenshots

screenshot 1
screenshot 2
screenshot 3
screenshot 4
screenshot 5
Swift Coding Challenges
View in iTunes
  • $24.99
  • Available on iPhone, iPad, iPod touch, and Mac.
  • Category: Programming
  • Published: Sep 30, 2016
  • Publisher: Paul Hudson
  • Seller: Paul Hudson
  • Print Length: 299 Pages
  • Language: English
  • Series: Hacking with Swift
  • Requirements: To view this book, you must have an iOS device with iBooks 1.3.1 or later and iOS 4.3.3 or later, or a Mac with iBooks 1.0 or later and OS X 10.9 or later.

Customer Ratings

We have not received enough ratings to display an average for this book.