O'Reilly logo

Special Edition Using Microsoft® Visual Basic® .NET by Jeff Spotts, Brian Siler

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using Math Operations

Processing numerical data is one of the key activities of many computer programs. Mathematical operations determine customer bills, interest due on savings or credit card balances, average scores for class tests, and many other bits of information. Visual Basic supports a number of different math operators that you can use in program statements. These operations and the Visual Basic symbol for each operation are summarized in Table 6.5. The operations are then described in detail in the following sections.

Table 6.5. Math Operations and the Corresponding Visual Basic Symbol
Operation Operator
Addition +
Subtraction -
Multiplication *
Division /
Integer division \
Modulus Mod
Exponentiation ^

In Visual Basic, you use mathematical ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required