title: Get an array instead of string
body: <p>After parsing my JSON I get the following value:</p>
  
  <pre><code>myArray = "[63, 83, 87, 71]"
  </code></pre>
  
  <p>How could I get an array instead of string? What I need is:</p>
  
  <pre><code>myArray = [63, 83, 87, 71]
  </code></pre>
  
  <p>Update:</p>
  
  <p>Here is my simple json:</p>
  
  <pre><code>{
      "0": "[31,47,51]",
      "1": "[74, 47, 51, 78]",
      "2": "[72, 65, 69, 80]",
      "3": "[63, 83, 87, 71]"
  }
  </code></pre>
  
  <p>Here is a parsing:</p>
  
  <pre><code>class gameModel: NSObject {
      func getCurrentArrays() -&gt; NSDictionary {
          let appBundlePath:String? = Bundle.main.path(forResource: "testJsonPrepared", ofType: "json")
  
          if let actualBundlePath = appBundlePath {
              let urlPath:NSURL? = NSURL(fileURLWithPath: actualBundlePath)
              if let actualUrlPath = urlPath {
                  let jsonData:NSData? = NSData(contentsOf: actualUrlPath as URL)
                  if let actualJsonData = jsonData {
                      let dict: NSDictionary? = (try? JSONSerialization.jsonObject(with: actualJsonData as Data, options: JSONSerialization.ReadingOptions.mutableContainers)) as! NSDictionary?
                      if let currentArrays = dict {
                          return currentArrays
                      }
                  }
              }
          }
          return NSDictionary()
      }
  }
  </code></pre>
  
  <p>Here is a final:</p>
  
  <pre><code>class GameScene: SKScene {
      let model = gameModel()
      var arrays: NSDictionary = ["":""]
  
      override func didMove(to view: SKView) {
          arrays = model.getCurrentArrays()
          print("# func viewDidLoad arrays: \(arrays)")
  
          let testKey = String(3)
  
          let testArray = arrays.value(forKey: testKey) as! String
          print("# func viewDidLoad testArray: \(testArray)")
      }
  }
  </code></pre>
  
  <p>===========</p>
  
  <p>Update2 Thanks, rmaddy. Here is my solution:</p>
  
  <p>testJson.json</p>
  
  <pre><code>{
    "0": [31,47,51],
    "1": [74, 47, 51, 78],
    "2": [72, 65, 69, 80],
    "3": [63, 83, 87, 71]
   }
  </code></pre>
  
  <p>here is reading from json:</p>
  
  <pre><code>class GameScene: SKScene {
  
  
  
  override func didMove(to view: SKView) {
  
      if let path = Bundle.main.path(forResource: "testJson", ofType: "json") {
          do {
              let data = try Data(contentsOf: URL(fileURLWithPath: path), options: .mappedIfSafe)
              let jsonResult = try JSONSerialization.jsonObject(with: data, options: .mutableLeaves)
              if let jsonResult = jsonResult as? Dictionary&lt;String, [Int]&gt;, let array = jsonResult["3"] {
                  print("# func didMove array: \(array)")
              }
          } catch {
              // handle error
          }
        }
      }
   }
  </code></pre>