'how to get count of array outside tableview method swift

I want to increase UIView size according to array count. Currently, I am doing this -:

var socialMediaURLSArray = [URL]()

and in View did load i am doing this -:

 viewHeightConstraints.constant = (60 * 1) + 170

In place of 1, I want to define socialMediaURLSArray count.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source