예제 #1
0
파일: Program.cs 프로젝트: kumbach/cctb145
        static void Main(string[] args)
        {
            Console.WriteLine("math expression: 123.45 X 67.89 = " + 123.45 * 67.89);

              HelloHelper helper = new HelloHelper();
              string name;
              for(;;)
              {
            Console.Write("Tell me a name: ");
            name = Console.ReadLine().Trim();
            if (name.Length == 0)
            {
              break;
            }
            helper.addPerson(name);
              };

              helper.sayHiToEveryone();
        }
예제 #2
0
        static void Main(string[] args)
        {
            Console.WriteLine("math expression: 123.45 X 67.89 = " + 123.45 * 67.89);

            HelloHelper helper = new HelloHelper();
            string      name;

            for (;;)
            {
                Console.Write("Tell me a name: ");
                name = Console.ReadLine().Trim();
                if (name.Length == 0)
                {
                    break;
                }
                helper.addPerson(name);
            }
            ;

            helper.sayHiToEveryone();
        }