Skip to content

Instantly share code, notes, and snippets.

@lizixroy
Created July 28, 2016 03:08
Show Gist options
  • Save lizixroy/ca9f69df174d853c11ee61b908a18fe0 to your computer and use it in GitHub Desktop.
Save lizixroy/ca9f69df174d853c11ee61b908a18fe0 to your computer and use it in GitHub Desktop.
for index in 0...words.count - 1 {
let word = words[index]
let nonTerminals = language.recognize([word])!
for nonTerminal in nonTerminals {
table[index][index].append(ParseTreeNode(nonTerminal: nonTerminal, leftNode: nil, rightNode: nil))
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment