UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

Checkpoint 9

Forums > 100 Days of SwiftUI

func rando(_ arrays: [Int]?) -> Int { arrays?.randomElement() ?? Int.random(in: 1...100)}

print(rando([17, 32, 55, 99]))
print(rando([]))

At first glance of the checkpoint I felt like I forgot everything but then I broke down challenge. Much easier than I thought originally, onto the review day!

2      

Please Read

Please read this thread and the response from @twoStraws. See-> How to Post Progress

In short, please keep posting your progress. However, instead of a new post for each day, you can edit this post!

Instead of the title "Checkpoint 9", consider changing your post title to: jmac's Progress: Day 9 Complete! Next week it will read: jmac's Progress: Day 16 Complete! Keep changing the title as you progress.

Add to the post! After each milestone and challenge, post a snip of your progress, your quiz scores, and the concepts you found fun, or difficult. There are other articles, blog posts, or YouTube videos we can point you to, to help you solidify a concept, or to push your boundaries.

Keep coding!

2      

TAKE YOUR SKILLS TO THE NEXT LEVEL If you like Hacking with Swift, you'll love Hacking with Swift+ – it's my premium service where you can learn advanced Swift and SwiftUI, functional programming, algorithms, and more. Plus it comes with stacks of benefits, including monthly live streams, downloadable projects, a 20% discount on all books, and free gifts!

Find out more

Sponsor Hacking with Swift and reach the world's largest Swift community!

Reply to this topic…

You need to create an account or log in to reply.

All interactions here are governed by our code of conduct.

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.