Inconsistency and a Tad Confusing

Took a while to understand if I was suppose to use Xcode on the Mac or Playgrounds on the Mac first of all. Or perhaps was I suppose to code in Playgrounds on the iPad, or perhaps use Playgrounds on the Mac to code then sync with iCloud to run it on the iPad!!! WHAT?

What is also the difference between using:

cave.torch1.accessibilityHints?.accessibilityLabel = "A bright, fire torch at the beginning"

OR

cave.torch1.accessibilityHints = AccessibilityHints(makeAccessibilityElement: true, accessibilityLabel: "does this one make any difference?")

Replies

tag: swans quest
We’re sorry for the confusion. The attached book can be run either in Swift Playgrounds for the Mac or for on iPad. (Or both, if you sync with iCloud).

To answer your code question, both are valid. The first version reuses the existing AccessibilityHints value, whereas the second code example creates a brand new AccessibilityHints value. Since we just need to change the label, we offer the first version as an example. However, both are valid and should work.