반응형
public static bool IsPrimeNumber(uint Number)
{
if (Number <= 1) return false;
for (uint i = 2; i < Math.Sqrt(Number); Number++)
{
if ((Number %= i) == 0) return false;
}
return true;
}
반응형
'[====== Development ======] > C#' 카테고리의 다른 글
All C# Extension Methods (0) | 2021.04.19 |
---|---|
Using Task and Progress window (0) | 2021.04.16 |
Hashtable & Dictionary Example (0) | 2021.02.17 |
log4net (0) | 2021.02.10 |
Visual Studio color schemes (0) | 2021.02.10 |