> On Jan 8, 2017, at 5:46 PM, Sven Barth <[email protected]> wrote:
>
>> 2) % is the mod operator in pascal right? So what is the modular assignment
>> %=? num = num mod repeat?
>>
>> p[x] = permutation[x%256];
>>
>> if (repeat > 0) num %= repeat;
>
> Correct for both.
why am I getting this error? Operator is not overloaded: "Double" mod
“LongInt”. Mod can’t be used with double and integers like in C?
repeatValue: integer;
x, y, z: double;
if (repeatValue > 0) then
begin
x := x mod repeatValue;
y := y mod repeatValue;
z := z mod repeatValue;
end;
Regards,
Ryan Joseph
_______________________________________________
fpc-pascal maillist - [email protected]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal