Ad
  • Default User Avatar

    There are not many PS people at CW so let us be kind:
    I modified the signature from:

    function prod-2-sum($a, $b, $c, $d)
    

    to

    function prod-2-sum([int]$a, [int]$b, [int]$c, [int]$d)
    

    .

  • Default User Avatar

    In PowerShell I had to cast the parameters as [int], otherwise when they were passed as negative numbers they were being treated as string

    Who treated them as strings? Negative numbers are [int] and they were passed as negative numbers; frankly I don't understand your problem.

  • Custom User Avatar

    You should mention the language you're having that problem. Those inputs seem weird.