Today we're going to write a function to generate Fermat numbers. This could be useful if you want to write your own pseudo-random number generator.
ASP
function fermat(x)
fermat = 2^2^x + 1
end function
PHP
function fermat($x)
{
return 2^2^$x + 1;
}
No comments:
Post a Comment