Hey, the solution is in the challenge file, thanx for the quick conversion to swift3/Xcode8 though.
Hello Brian,
Should all classes and or structs that you create be in their own separate file?
I can see were subclasses of your class could and probably should be in the same
file as your class.
Thanks,
Gary
Itโs really up to you, your team, or your style guide. A good rule of thumb is to group classes together that are all interrelated and have dependencies on each other. Otherwise, keep them apart. I hope that helps!
Thatโs good to know, Brian. I guess I had some pre-conceived idea that each
class needed to be in its own separate file.
Thanks,
Gary
Can I use struct but I still want to use the reference? Like what we did in C/C++?
let a = &b // something like that to tell swift I want to use a reference
Can I use class but I donโt want to use the reference?
let x = copy(y) // something like that to tell swift a explicit copy should be made