From ebad8396345a73fcb0af9e7f45edf04dce9842b2 Mon Sep 17 00:00:00 2001 From: David Foster Date: Sun, 5 Jan 2014 16:00:32 -0800 Subject: [PATCH] Wordsmith comments about word-frequency records. --- 01-good-old-times/tf-01.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/01-good-old-times/tf-01.py b/01-good-old-times/tf-01.py index 5b913a5..9ca8a40 100755 --- a/01-good-old-times/tf-01.py +++ b/01-good-old-times/tf-01.py @@ -40,7 +40,7 @@ data.append(None) # data[2] is index of the start_char of word data.append(0) # data[3] is index on characters, i = 0 data.append(False) # data[4] is flag indicating if word was found data.append('') # data[5] is the word -data.append('') # data[6] is word,NNNN and then just word +data.append('') # data[6] is word,NNNN data.append(0) # data[7] is frequency # Open the secondary memory @@ -104,7 +104,7 @@ del data[:] # Let's use the first 25 entries for the top 25 words data = data + [[]]*(25 - len(data)) -data.append('') # data[25] is word,freq from file, and then word +data.append('') # data[25] is word,freq from file data.append(0) # data[26] is freq # Loop over secondary memory file