private void UpdateData()
        {
            DataStackPanel.Children.Clear();
            var entries = TuringMachine.Data.ToArray();

            foreach (var entry in entries)
            {
                DataStackPanel.Children.Add(new TuringMachineEntry(entry, entry == TuringMachine.Data.Center));
            }

            var instruction = TuringMachine.GetInstruction();

            CurrentStateLabel.Content = TuringMachine.CurrentState;
            CurrentDataLabel.Content  = TuringMachine.Data.CurrentData;
            if (instruction != null)
            {
                NextStateLabel.Content = instruction.InstructionExitState;
                InputDataLabel.Content = instruction.InstructionOutput;
                MovementLabel.Content  =
                    instruction.InstructionMovement == TuringMachineInstruction.Movement.Left ? "<" : ">";
            }
            else
            {
                NextStateLabel.Content = "";
                InputDataLabel.Content = "";
                MovementLabel.Content  = "";
            }

            MachineStateLabel.Content =
                TuringMachine.MachineState == TuringMachine.State.Finished
                    ? TuringMachine.Result.ToString()
                    : TuringMachine.MachineState.ToString();

            if (TuringMachine.MachineState == TuringMachine.State.Finished)
            {
                ResultBorder.Visibility = Visibility.Visible;
                ResultBorder.Background =
                    TuringMachine.Result == TuringMachine.FinishResult.Valid
                        ? Brushes.SpringGreen
                        : Brushes.Crimson;
            }
            else
            {
                ResultBorder.Visibility = Visibility.Hidden;
            }
        }