Esempio n. 1
0
        public void Teste_Count_Words()
        {
            WordCount wordCount = new WordCount();

            wordCount.Count_Words();

            Assert.That(5);
        }
Esempio n. 2
0
        public static void Start()
        {
            WordCount wordCount = new WordCount();

            while (true)
            {
                Ui.Start();

                string text        = Ui.Bitte_um_Texteingabe();
                int    anzahlWords = wordCount.Count_Words(text);

                Ui.Zeige_Anzahl_Woerter(anzahlWords);
                Ui.Warte_und_Neustart();
            }
        }
Esempio n. 3
0
        static void Main(string[] args)
        {
            // Config
            string stopwordsFilePath = @"C:\Users\jakl\Documents\Home\Software\Schulung\Lieser\SimpleApplication\SimpleApplication\Config\stopwords.txt";


            // UI
            Console.Write("Enter your text: ");
            string text = Console.ReadLine();


            // Business
            WordCount wordCount = new WordCount();
            int       counter   = wordCount.Count_Words(text, stopwordsFilePath);


            //UI
            Console.Write("Number of Words: " + counter);
            Console.ReadKey();
        }