I’m wanting to understand in a little more detail what the code within the parentheses actually does? When I was watching the video, I didn’t quite latch on, and I’m trying to read into the things that I’m not 100% sure about… any assistance would be greatly appreciated…
@IBAction → This is a tag that tells Xcode that this function can be connected to an UIElement
func → this is used to define a function
sliderMoved → This is the name of the function
_ → This indicates the name of the parameter. generally a function that is defined as say func add(number1: Int, number2: Int) means that it takes two parameters and the first is called number1 and the other number2. The names are used both for internal (used inside the function) and external use (used for calling). The function would be called as add(number1: 1, number2: 2). If the function was defined as func add(_ number1: Int, number2: Int) then it is called as add(1, number2: 2) lastly, you can also define the function as func add(_ number1: Int, second number2: Int) and call this function as add(1, second: 2) where you call the function using the parameter name second where as internally the two parameters are referenced as number1 and number2.
slider → This is the internal name of the parameter that will be used int he function
UISlider → This is the type of the parameter, in the examples under #4. the parameters are of type Int and in this case it is of type UISlider.