public void UpdateStats(wordFunctions wordFunctions, string wordRegex, string word) { foreach (int index in wordFunctions.firstClassFunctions) { if (this.FunctionsStats[index].requiredWords.Contains(wordRegex)) { this.FunctionsStats[index].requiredWords.Remove(wordRegex); } this.FunctionsStats[index].words.Add(word); this.FunctionsStats[index].Score += 4; } foreach (int index in wordFunctions.SecondClassFunctions) { this.FunctionsStats[index].Score += 2; this.FunctionsStats[index].words.Add(word); } }
public void UpdateStats(wordFunctions wordFunctions, string wordRegex, string word) { foreach (int index in wordFunctions.firstClassFunctions) { if (this.FunctionsStats[index].requiredWords.Contains(wordRegex)) this.FunctionsStats[index].requiredWords.Remove(wordRegex); this.FunctionsStats[index].words.Add(word); this.FunctionsStats[index].Score += 4; } foreach (int index in wordFunctions.SecondClassFunctions) { this.FunctionsStats[index].Score += 2; this.FunctionsStats[index].words.Add(word); } }