public static void PrintNoisyChannelScore(string inStr, HashSet <string> candSet, WordWcMap wordWcMap, int maxCandNo, double wf1, double wf2, double wf3, bool debugFlag) { if (debugFlag == true) { NoisyChannelScoreComparator <NoisyChannelScore> ncsc = new NoisyChannelScoreComparator <NoisyChannelScore>(); HashSet <NoisyChannelScore> ncScoreSet = RankByNoisyChannel.GetCandidateScoreSet(inStr, candSet, wordWcMap, wf1, wf2, wf3); var list = ncScoreSet.OrderBy(x => x, ncsc).Take(maxCandNo).Select(obj => obj.ToString()).ToList(); foreach (var item in list) { DebugPrint.PrintNScore(item, debugFlag); } } }