PDA

View Full Version : mod and div functions


alaios
09-26-2002, 11:15 AM
do u know how i can use the mod and div functions in javascript?
i am trying this but it does not work
(i)mod(5)

jkd
09-26-2002, 12:06 PM
i % 5

translates into "i mod 5"

alaios
09-26-2002, 05:22 PM
?

adios
09-26-2002, 05:25 PM
Actually they're operators....

http://www.w3schools.com/js/js_operators.asp

jkd
09-26-2002, 07:55 PM
Originally posted by adios
Actually they're operators....

http://www.w3schools.com/js/js_operators.asp

How can they call that a reference when it is missing a bunch of operators!

Mainly the bitwise operations and related assignments (7 bitwise, 6 bitwise assignment, the new operator, etc).

See a complete list here:
http://devedge.netscape.com/library/manuals/2000/javascript/1.5/reference/ops.html#1003191