I want to determine the background colour of an imageview when it is tapped and perform an action based on the colour. I cannot fathom the syntax for getting the information from the array in which the imageviews are stored. I have tried the below but it says the stated error. Any help would be appreciated. I am new and I'm sorry if I'm wasting peoples time, I'm learning by making my own app and its throwing up a lot of questions. Kind regards.
'Value of type [UIImageView] has no member backgroundColour.
@IBAction func onTapping() {
if squares.backgroundColor == UIColor.red {
// code
}
}