You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

10 lines
199 B

4 years ago
  1. filename = 'atis/train/seq.out'
  2. blah = set()
  3. with open(filename) as f:
  4. for line in f:
  5. line = line.rstrip().split()
  6. for word in line:
  7. blah.add(word)
  8. print(len(blah))