$pow = [system.math]::Pow(1237,25)
$pow
$res = $pow % 351
$res
Here is one part of a Diffie Hellman key exchange formula, in PS v4 $res comes out to be 35, however the real answer should be 67 which I verified on two independent calculators.
Does anyone know why powershell is not calculating this number correctly?
Actually I am not sure if the pow and/or % are the problem here?