Hello everyone,
I was working on a Xcode playground, and unexpectedly it appeared an error that I can't understand how to fix.
Here's the error that I'm facing.
Does someone know how to fix it?
Thanks in advance ;)
someone will be able to help you if you post the code itself, rather than a screenshot of a fragment of it (format it as code so it is readable).
It seems that you wrote an init() function that does nothing. In the struct or class which you are initializing, there are properties declared like this:
var whatever: String
or
var somethingElse: Float
for example
Either declare them with initial values
var whatever = "Hello"
var somethingElse = 1.0
or give them values in your init(), perhaps like this
init() {
whatever = "goodbye"
somethingElse = someThingComplicatedThatReturnsAFloat()
}