static void Main(string[] args)
        {
            Table table = new Table();
            Servant servant = new Servant();
            Smoker[] smokers = {
                new Smoker(Resource.TypeEnum.MATCHES),
                new Smoker(Resource.TypeEnum.TOBACCO),
                new Smoker(Resource.TypeEnum.PAPER)
            };

            SmokingRoom room = new SmokingRoom(table, servant, smokers);
            room.startSmoking();
        }
示例#2
0
        static void Main(string[] args)
        {
            Table   table   = new Table();
            Servant servant = new Servant();

            Smoker[] smokers =
            {
                new Smoker(Resource.TypeEnum.MATCHES),
                new Smoker(Resource.TypeEnum.TOBACCO),
                new Smoker(Resource.TypeEnum.PAPER)
            };

            SmokingRoom room = new SmokingRoom(table, servant, smokers);

            room.startSmoking();
        }