Example #1
0
        private void SetPrecisely(RandomNumber GeneratedRandomNumber, UserNumber EnteredUserNumber)
        {
            if (GeneratedRandomNumber.FirstNumber.Value == EnteredUserNumber.FirstNumber.Value)
            {
                Precisely += '*';
            }

            if (GeneratedRandomNumber.SecondNumber.Value == EnteredUserNumber.SecondNumber.Value)
            {
                Precisely += '*';
            }

            if (GeneratedRandomNumber.ThirdNumber.Value == EnteredUserNumber.ThirdNumber.Value)
            {
                Precisely += '*';
            }

            if (GeneratedRandomNumber.FourthNumber.Value == EnteredUserNumber.FourthNumber.Value)
            {
                Precisely += '*';
            }
        }
Example #2
0
 public EnteredNumber(RandomNumber GeneratedRandomNumber, UserNumber EnteredUserNumber)
 {
     Number = EnteredUserNumber.Value;
     SetPrecisely(GeneratedRandomNumber, EnteredUserNumber);
     SetBeside(GeneratedRandomNumber, EnteredUserNumber);
 }