Browse Groups

• Hello NoteTabbers, I am attempting to customize a clip that was posted to this list several months ago. My question concerns the use of two functions that I do
Message 1 of 2 , Sep 3, 2001
View Source
Hello NoteTabbers,

I am attempting to customize a clip that was posted to this list
several months ago. My question concerns the use of two functions
that I do not recognize.

From the Help topic "Calculate in NoteTab";

"NoteTab can also calculate mathematical expressions in a
document. Expressions can have up to 40 imbedded parentheses.

[...Snipped for brevity...]

Accepted operators:

+ , - , * , / , ^ , MOD, DIV"

I'm doing fine with this topic up to this point, except that I do
not understand the use of the operators "MOD" and "DIV". Can someone
provide a brief explanation?

TIA
Ben
• ... The div Operator The div operator stands for integer division. The operands must be integer and its result is integer. The result of A div B is the integer
Message 2 of 2 , Sep 3, 2001
View Source
At 02:05 PM 9/3/01 -0700, you wrote:
>Hello NoteTabbers,
>
>I am attempting to customize a clip that was posted to this list
>several months ago. My question concerns the use of two functions
>that I do not recognize.
>
> >From the Help topic "Calculate in NoteTab";
>
> "NoteTab can also calculate mathematical expressions in a
> document. Expressions can have up to 40 imbedded parentheses.
>
> [...Snipped for brevity...]
>
> Accepted operators:
>
> + , - , * , / , ^ , MOD, DIV"
>
>
>I'm doing fine with this topic up to this point, except that I do
>not understand the use of the operators "MOD" and "DIV". Can someone
>provide a brief explanation?

The div Operator
The div operator stands for integer division. The operands must be integer
and its result is integer. The result of
A div B
is the integer you get when you divide A by B and throw away any remainder.
For example,
7 div 2
is the integer 3.
-7 div 2
is the integer -3.
The mod Operator
The mod operator stands for the mathematical ``modulo'' operation. Its
operands must both be integer. The general form of the operation is
A mod B
where A and B are expressions. The value of B must be positive.
The result of the mod operation is always non-negative, and is equal to A
modulo B. If A is non-negative, this value will be equal to
A - ( (A div B) * B )
In other words, it is the non-negative remainder that is left after A is
divided by B.

modulo modulo (moj'-l`, mod'y-l`) noun
An arithmetic operation whose result is the remainder of a division
operation. For example, 17 modulo 3 = 2 because 17 divided by 3 yields a
remainder of 2. Modulo operations are used in programming.

[Non-text portions of this message have been removed]
Your message has been successfully submitted and would be delivered to recipients shortly.
• Changes have not been saved
Press OK to abandon changes or Cancel to continue editing
• Your browser is not supported
Kindly note that Groups does not support 7.0 or earlier versions of Internet Explorer. We recommend upgrading to the latest Internet Explorer, Google Chrome, or Firefox. If you are using IE 9 or later, make sure you turn off Compatibility View.