forked from satwikkansal/wtfpython
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathadd_categories
More file actions
152 lines (102 loc) · 1.59 KB
/
add_categories
File metadata and controls
152 lines (102 loc) · 1.59 KB
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
Skipping lines?
a
Well, something is fishy...
a
Time for some hash brownies!
f
Evaluation time discrepancy
f
Modifying a dictionary while iterating over it
c
Deleting a list item while iterating over it
c
Backslashes at the end of string
f
Brace yourself!
t*
"this" is love :heart:
t*
Okay Python, Can you make me fly?
t*
`goto`, but why?
t*
Let's meet Friendly Language Uncle For Life
t*
Inpinity
t*
Strings can be tricky sometimes
f*
`+=` is faster
m
Let's make a giant string!
m
Yes, it exists!
t
`is` is not what it is!
f
`is not ...` is not `is (not ...)`
f
The function inside loop sticks to the same output
f
Loop variables leaking out of local scope!
c
A tic-tac-toe where X wins in the first attempt!
f
Beware of default mutable arguments!
c
Same operands, different story!
c
Mutating the immutable!
f
Using a variable not defined in scope
c
The disappearing variable from outer scope
f
Return return everywhere!
f
When True is actually False
f
Be careful with chained operations
c
Name resolution ignoring class scope
c
From filled to None in one instruction...
f
Explicit typecast of strings
m
Class attributes and instance attributes
f
Catching the Exceptions!
f
Midnight time doesn't exist?
f
What's wrong with booleans?
f
Needle in a Haystack
c
Teleportation
a*
yielding None
f
The surprising comma
f
For what?
f
not knot!
f
Subclass relationships
f*
Mangling time!
t*
Deep down, we're all the same.
f*
Half triple-quoted strings
f
Implicity key type conversion
f*
Stubborn `del` operator
c*
Let's see if you can guess this?
f
Minor Ones
m