コード例 #1
0
 public Quintet(TFirst first, TSecond second, TThird third, TFourth fourth, TFifth fifth, string[] propertyNames)
     : base(first, second, third, fourth, propertyNames)
 {
     Fifth = fifth;
     Collection[UniqueIdentifier].Add(Fifth.ToString());
     KeyIndex = 4;
 }
コード例 #2
0
ファイル: EulerProblem060.cs プロジェクト: BobHemphill/Euler
 public bool IsFivePrimeTuple()
 {
     return             /*IsFourPrimeTuple() &&*/
            (Primes.IsPrimeInLine(Int64.Parse(First.ToString() + Fifth.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Second.ToString() + Fifth.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Third.ToString() + Fifth.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Fourth.ToString() + Fifth.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Fifth.ToString() + First.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Fifth.ToString() + Second.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Fifth.ToString() + Third.ToString())) &&
             Primes.IsPrimeInLine(Int64.Parse(Fifth.ToString() + Fourth.ToString())));
 }