Adding solutions in Swift for first 3 questions

Solutions in a single Swift playground file.