Mod Remainder ASP Function

Mod Remainder ASP Function
The mod function is rarely used in asp, but what it does is provide the remainder value in a division situation.

If you don't remember your basic math, the remainder is what is left over after you do a division problem. For example:

20 / 5 = 4, remainder 0

18 / 5 = 3, remainder 3

10 / 3 = 3, remainder 1

The format in ASP to get that remainder is

Remain = val1 mod val2

so if you wanted to find the remainder of 10 / 3, you would say

remain = 10 mod 3

or

val1 = 10
val2 = 3

remain = val1 mod val2




RSS
Editor's Picks Articles
Top Ten Articles
Previous Features
Site Map





Content copyright © 2023 by Lisa Shea. All rights reserved.
This content was written by Lisa Shea. If you wish to use this content in any manner, you need written permission. Contact Lisa Shea for details.