pascalabcnet/TestSuite/CompilationSamples/TextFileCount.pas
Бондарев Иван 44eb7e8b32 bug fix issue #27, #25
2015-12-31 12:47:14 +01:00

7 lines
263 B
ObjectPascal

begin
var d := new Dictionary<string,integer>;
foreach var s in ReadLines('TextFileCount.pas') do
foreach var word in s.ToWords(' ',':',')','(',';','''',',','.','=','<','>','[',']','+','-') do
d[word] := d.Get(word) + 1;
d.Print(NewLine);
end.