From 01746a0e03267b6c082b58436c1370567f7cb7c5 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sun, 22 Nov 2015 18:49:58 -0500 Subject: Added malapropisms --- kgramstats.h | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'kgramstats.h') diff --git a/kgramstats.h b/kgramstats.h index 059eb05..b01dece 100644 --- a/kgramstats.h +++ b/kgramstats.h @@ -2,19 +2,18 @@ #include #include #include - -using namespace::std; +#include "malaprop.h" #ifndef KGRAMSTATS_H #define KGRAMSTATS_H -typedef list kgram; +typedef std::list kgram; class kgramstats { public: - kgramstats(string corpus, int maxK); - vector randomSentence(int n); + kgramstats(std::string corpus, int maxK); + std::vector randomSentence(int n); private: typedef struct @@ -28,13 +27,13 @@ private: int startparen; int endparen; int comma; - string* token; + std::string* token; } token_data; int maxK; - map* >* stats; + std::map* >* stats; + malaprop mstats; }; void printKgram(kgram k); -std::string canonize(std::string f); #endif \ No newline at end of file -- cgit 1.4.1