File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,6 @@ def print_groups(match):
31
31
print_groups (m )
32
32
33
33
# named class within a class set
34
- print_groups (re .match ("([^\s]+)\s*([^\s]+)" , "1 23" ))
35
- print_groups (re .match ("([\s\d]+)([\W]+)" , "1 2-+=" ))
36
- print_groups (re .match ("([\W]+)([^\W]+)([^\S]+)([^\D]+)" , " a_1 23" ))
34
+ print_groups (re .match (r "([^\s]+)\s*([^\s]+)" , "1 23" ))
35
+ print_groups (re .match (r "([\s\d]+)([\W]+)" , "1 2-+=" ))
36
+ print_groups (re .match (r "([\W]+)([^\W]+)([^\S]+)([^\D]+)" , " a_1 23" ))
Original file line number Diff line number Diff line change @@ -15,9 +15,9 @@ def multiply(m):
15
15
return str (int (m .group (0 )) * 2 )
16
16
17
17
18
- print (re .sub ("\d+" , multiply , "10 20 30 40 50" ))
18
+ print (re .sub (r "\d+" , multiply , "10 20 30 40 50" ))
19
19
20
- print (re .sub ("\d+" , lambda m : str (int (m .group (0 )) // 2 ), "10 20 30 40 50" ))
20
+ print (re .sub (r "\d+" , lambda m : str (int (m .group (0 )) // 2 ), "10 20 30 40 50" ))
21
21
22
22
23
23
def A ():
You can’t perform that action at this time.
0 commit comments