Exemple #1
0
        static void Main(string[] args)
        {
            var words = Counter.CountWords("This is the longest string I've ever written!");

            Console.WriteLine("The longest string you've ever written is {0} words long!", words);
            Console.ReadLine();
        }
Exemple #2
0
        static void Main(string[] args)
        {
            Counter taco1 = new Counter{};
            taco1.CountWords("taco taco burrito burrito");

            Console.WriteLine(taco1.NumberOfWords);
            Console.ReadLine();

        }
Exemple #3
0
        static void Main(string[] args)
        {
            Counter taco1 = new Counter {
            };

            taco1.CountWords("taco taco burrito burrito");

            Console.WriteLine(taco1.NumberOfWords);
            Console.ReadLine();
        }