Skip to content

Commit 235f909

Browse files
authored
Merge pull request mouredev#6311 from h4ckxel/main
#14 - Python
2 parents 84feb14 + 8156785 commit 235f909

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
def main():
2+
test_list = [1, 2, 3, 4]
3+
4+
test_list.insert(0, 0)
5+
test_list.append(5)
6+
test_list += [6, 7, 8]
7+
test_list[3:3] = [9, 10]
8+
test_list.pop(3)
9+
test_list[3] = 3
10+
is_in_list = True if 10 in test_list else False
11+
test_list.clear()
12+
13+
union_list = list(set([0, 1, 3, 2]) | set([4, 1, 2]))
14+
intersection_list = list(set([0, 1, 3, 2]) & set([4, 1, 2]))
15+
difference_list = list(set([0, 1, 3, 2]) - set([4, 1, 2]))
16+
simetric_difference_list = list(set([0, 1, 3, 2]) ^ set([4, 1, 2]))
17+
18+
19+
if __name__ == '__main__':
20+
main()

0 commit comments

Comments
 (0)