示例#1
0
        [HttpPost] //shows the number of lit pixels, along with the actual screen display for part 2
        public ActionResult DisplayScreen(EncodedInstructions instructions)
        {
            instructions.Input = HttpUtility.UrlDecode(instructions.Input);
            AuthenticationScreen screen = new AuthenticationScreen();

            foreach (InstructionStep step in instructions.StepsFromInput)
            {
                screen.UpdateScreen(step);
            }

            FinalDisplay display = new FinalDisplay(screen.Pixels);

            return(PartialView("Display", display));
        }
示例#2
0
        // GET: Day8
        public ActionResult Index()
        {
            EncodedInstructions instructions = new EncodedInstructions();

            return(View(instructions));
        }