-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprogram18.py
More file actions
31 lines (28 loc) · 746 Bytes
/
program18.py
File metadata and controls
31 lines (28 loc) · 746 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
#List (Part-1)---------
Subjects = ["C","Java","C++","C#","Roby","Python","Swift"]
print(Subjects)
print(Subjects * 2)
print(Subjects + ["Go",25],26)
print(Subjects[5])
print(Subjects[3:])
print(Subjects[:3])
print(Subjects[-2])
print("Roby" in Subjects)
print("Roby" not in Subjects)
print("Go" in Subjects)
print("Go" not in Subjects)
print("\n")
#List (Part-1)---------
Student = ["Arif","Tamim","Nazim","Ayon","Rajon","Nahid"]
print(Student)
print(Student * 2)
print(Student +["Tanvir",22])
print(Student +["Abu",20],22)
print(Student[2])
print(Student[-2])
print(Student[4:])
print(Student[:4])
print("Tamim" in Student)
print("Tamim" not in Student)
print("Noyon" in Student)
print("Noyon" not in Student)