title: Reference an array which was created by another function
body: <p>I have the below Struct </p>
  
  <pre><code>struct KStruct {
  let SongTitle: String
  let SongLyrics: String
  let ESongTitle: String
  
   init(SongTitle: String, SongLyrics:String, ESongTitle: String) {
      self.SongTitle =  SongTitle
      self.SongLyrics = SongLyrics
      self.ESongTitle = ESongTitle
  }
  func match(string:String) -&gt; Bool {
      let lowerCaseKeyword = string.lowercaseString
      return SongTitle.lowercaseString.containsString(lowerCaseKeyword) || ESongTitle.containsString(lowerCaseKeyword)
  
      }
  }
  </code></pre>
  
  <p>I am converting this as an array and I am populating this array in a loop like below in the viewDidload function</p>
  
  <pre><code>let keerthanaiArray = KStruct(SongTitle : songTitleT!, SongLyrics : songLyricsT!,
                                      ESongTitle : EsongTitleT!)
  </code></pre>
  
  <p>Now I am trying to refer this Array in an another function filterContentForSearchText                         </p>
  
  <p>But I am unable to do so as the array is not recognized outside of its own function.  How do I read this array in another function.  Please help</p>