THE BASIC PROGRAMMING LANGUAGE
CONTENT
- BASIC Arithmetic Operators
- BASIC Arithmetic Expressions
- Evaluation of Expressions
- Simple BASIC Programs
BASIC Arithmetic Operators
They are expressed in terms of a hierarchy of operators in which operations of high priority are performed first.
Examples:
Operator Symbol | Operation |
---|---|
^ | Exponentiation |
* | Multiplication |
/ | Division |
+ | Addition |
– | Subtraction |
BASIC Arithmetic Expressions
These arithmetic Expressions are not formed according to the same rules of Algebra and Mathematics. The following symbols are used to denote arithmetic operations.
Operators | Meaning | Basic Expression | Math Equivalent |
---|---|---|---|
+ | Addition | \(A= A + B\) | \(A = A + B\) |
– | Subtraction | \(Sum = Sum -10\) | \(Sum = Sum -10\) |
* | Multiplication | \(J = J * 4\) | \(J = 4J\) |
/ | Division | \(Pi = \frac{22}{7}\) | \(Pi = \frac{22}{7}\) |
^ | Exponentiation | \(J = J + 2^2\) | \(J = J + 2^2\) |
Basic Relational Operators
Operator | Relation Tested | Expression |
---|---|---|
= | Equality | \(X = Y\) |
< > | Inequality | \(X < > Y\) |
< | Less than | \(X < Y\) |
> | Greater than | \(X > Y\) |
<= | Less than or equal to | \(X <= Y\) |
>= | greater than or equal to | \(X >= Y\) |
EVALUATION
- What do you understand by BASIC Arithmetic Operators?
You are viewing an excerpt of this lesson. Subscribing to the subject will give you access to the following:
- NEW: Download the entire term's content in MS Word document format (1-year plan only)
- The complete lesson note and evaluation questions for this topic
- The complete lessons for the subject and class (First Term, Second Term & Third Term)
- Media-rich, interactive and gamified content
- End-of-lesson objective questions with detailed explanations to force mastery of content
- Simulated termly preparatory examination questions
- Discussion boards on all lessons and subjects
- Guaranteed learning