Esempio n. 1
0
        public static int Main(string[] args)
        {
            var path   = new PathToEnlightenment();
            var sensei = new Sensei(Reporter.Output);

            return(path.Walk(sensei, AnsiConsole.GetOutput()));
        }
Esempio n. 2
0
        public static int Main(string[] args)
        {
            var reporter = Reporter.Output;
            var sensei   = new Sensei(reporter);
            var path     = new PathToEnlightenment();

            return(path.Walk(sensei));
        }
Esempio n. 3
0
        public int Walk(Sensei sensei, AnsiConsole console)
        {
            try
            {
                ForEachStep(step => {
                    sensei.Observe(step.Meditate());
                });
            }
            catch (SenseiException e)
            { }

            sensei.Instruct(console);

            return(sensei.Failed() ? -1 : 0);
        }