Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

iOS Swift Basics Swift Operators Unary Operators

2 Answers

Pasan Premaratne
STAFF
Pasan Premaratne
Treehouse Teacher

You're right. Looks like they changed this naming in Swift 3.0.1. I'll update the course. Thanks!!

SivaKumar Kataru
SivaKumar Kataru
2,386 Points

Also, Apple has removed the legacy UNARY operators ++ and -- in swift 3.0 .

William Squires
PLUS
William Squires
Courses Plus Student 2,817 Points

And the video forgot to mention the unary '-' operator which changes the sign of a number. i.e.

var x = 3 let minusX = -x // = -3