-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path13operater.py
More file actions
50 lines (40 loc) · 835 Bytes
/
Copy path13operater.py
File metadata and controls
50 lines (40 loc) · 835 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Operators In Pythons
# Arithmetic Operators
# Assignment Operators
# Comparison Operators
# Logical Operators
# Identity Operators
# Membership Operators
# Bitwise Operators
# Arithmetic Operators
# print("5 + 6 is ", 5+6)
# print("5 - 6 is ", 5-6)
# print("5 * 6 is ", 5*6)
# print("5 / 6 is ", 5/6)
# print("5 * 3 is ", 5*3)
# print("5 % 5 is ", 5%5)
# print("15 // 6 is ", 15//6)
# Assignment Operators
# print("Assignment Operators")
# x = 5
# print(x)
# x %=7 # x = x%7
# print(x)
# Comparison Operators
i = 5
# Logical Operators
a = True
b = False
# print(a and b)
# Identity Operators
# print(5 is not 5)
# Membership Operators
list = [3, 3,2, 2,39, 33, 35,32]
# print(324 not in list)
# Bitwise Operators
# 0 - 00
# 1 - 01
# 2 - 10
# 3 - 11
print(0 & 2)
print(0 | 3)