diff options
-rw-r--r-- | kgramstats.cpp | 4 | ||||
-rw-r--r-- | kgramstats.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/kgramstats.cpp b/kgramstats.cpp index 899ad20..38bf973 100644 --- a/kgramstats.cpp +++ b/kgramstats.cpp | |||
@@ -457,7 +457,7 @@ void printKgram(kgram k) | |||
457 | } | 457 | } |
458 | 458 | ||
459 | // runs in O(n log t) time where n is the input number of sentences and t is the number of tokens in the input corpus | 459 | // runs in O(n log t) time where n is the input number of sentences and t is the number of tokens in the input corpus |
460 | std::string kgramstats::randomSentence(int max) | 460 | std::string kgramstats::randomSentence(int maxL) |
461 | { | 461 | { |
462 | std::string result; | 462 | std::string result; |
463 | kgram cur(1, wildcardQuery); | 463 | kgram cur(1, wildcardQuery); |
@@ -613,7 +613,7 @@ std::string kgramstats::randomSentence(int max) | |||
613 | } | 613 | } |
614 | 614 | ||
615 | // Went over the limit, so reset | 615 | // Went over the limit, so reset |
616 | if (result.length() > max) | 616 | if (result.length() > maxL) |
617 | { | 617 | { |
618 | result = ""; | 618 | result = ""; |
619 | cur = kgram(1, wildcardQuery); | 619 | cur = kgram(1, wildcardQuery); |
diff --git a/kgramstats.h b/kgramstats.h index a024184..5fad37d 100644 --- a/kgramstats.h +++ b/kgramstats.h | |||
@@ -97,7 +97,7 @@ class kgramstats | |||
97 | { | 97 | { |
98 | public: | 98 | public: |
99 | kgramstats(std::string corpus, int maxK); | 99 | kgramstats(std::string corpus, int maxK); |
100 | std::string randomSentence(int max); | 100 | std::string randomSentence(int maxL); |
101 | 101 | ||
102 | private: | 102 | private: |
103 | struct token_data | 103 | struct token_data |