Пример #1
0
        static void Main(string[] args)
        {
            Console.WriteLine("Hello World!");
            NumberConversion _conversionService = new NumberConversion();
            string           result             = _conversionService.NumToWords(21656704);

            Console.WriteLine(result);
            long no = _conversionService.WordsToNum("Twenty One Million Six Hundred and Fifty Six Thousand and Seven Hundred and Four");

            Console.WriteLine(no);
        }
Пример #2
0
        public void Test_WordsToNum()
        {
            var result = _conversionService.WordsToNum("Five Thousand and Twelve");

            Assert.AreEqual(5012, result);
        }