Check out example codes for "how to create a uicolor array in swift". It will help you in understanding the concepts better.

Code Example 1

var uiColorArray = [UIColor]()   // Empty Array of type UIColor

Learn ReactJs, React Native from akashmittal.com