I try to use Firebase framework and use it in my app, but I have a problem with undestanding, how to retrieving data from firebase and save it in my own array. Firebase structure is very simple and looks like that:

Now my code looks like that:
`var rootRef = Firebase(url: "https://mathgamepio.firebaseio.com/")
var array:[String]?
var count: Int = 0
override func viewDidLoad() {
super.viewDidLoad()
rootRef.observeEventType(.ChildAdded) { (snap: FDataSnapshot!) -> Void in
self.count++
let math = snap.value["math"] as! String
print(self.count)
print(math)
self.array?.append(math)
print(self.array)
print("--------")
}`
The result of this operation looks like that:
self.array.append doesn't work and is nil always. How to add this data to my own array?
