Featured
- Get link
- X
- Other Apps
Operators-Arithmatic
Operators:
In this post we are going to learn about operators, we use operators in order to manage types of operations and in this we are going to talk about the difference and application
Types of operators:
1. Arithmetic operator
2. Assignment operator
3. Comparison operator
4. Logical operator
5. Membership operator
6. Bit wise operator
1. Arithmetic operator
The simplest operator are arithmetic operator you probably already know them from mathematics
ARITHMETIC OPERATORS
+ Addition Adds two values
- Subtraction Subtracts one value from another
* Multiplication Multiplies two values
/ Division Divides one value by another
% Modulus Returns the remainder of a division
** Exponent Takes a value to the power of another value
// Floor Division Returns the result of a division without decimal places
Example:
20 + 10 = 30
20 - 10 = 10
2 * 10 = 20
5 / 2 = 2.5
5 % 2 = 1
5 ** 2 = 25
5 // 2 = 2
you can also use variables and not only pure values.
Output:
In next post lets see about assignment operator
- Get link
- X
- Other Apps
Comments

It was more useful😊
ReplyDeleteTq for your comment
Delete