title: How to get array of UIImage, from folder, in Swift?
body: <p>I have an ordinary Xcode project like this ...</p>
  
  <p><a href="https://i.stack.imgur.com/QOQam.png" rel="noreferrer"><img src="https://i.stack.imgur.com/QOQam.png" alt="enter image description here"></a></p>
  
  <p>notice there's a folder (it is an actual folder - not just a group) named "images". It contains 25 ".png" images.</p>
  
  <p>All I want to do is make an <strong>array of</strong> <code>UIimage</code> with each of those images. </p>
  
  <p>(Or even, an array of the image names or similar, that would be fine - then could load them <code>UIImage(named:</code>)</p>
  
  <p>How do I get at that folder "images"??  What about a subfolder "images/cars"?</p>
  
  <p>I tried something like this but it finds nothing...</p>
  
  <pre><code>override func viewDidLoad()
      {
      let imageArray = NSBundle.mainBundle().URLsForResourcesWithExtension(
            "png", subdirectory: "images")
      print("test...")
      for n:NSURL in imageArray!
          { print("found ..." ,n) }
      }
  </code></pre>