ex D
This commit is contained in:
parent
abd0e8fd7f
commit
6b3df7cf2b
7
TaskD01/run.py
Normal file
7
TaskD01/run.py
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
import re
|
||||||
|
import sys
|
||||||
|
|
||||||
|
for line in sys.stdin:
|
||||||
|
stripped_line = line.strip()
|
||||||
|
if re.search("Hamlet", stripped_line):
|
||||||
|
print(stripped_line)
|
2
TaskD01/simple.out
Normal file
2
TaskD01/simple.out
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
Here comes Hamlet
|
||||||
|
Hamlet Hamlet again
|
7
TaskD02/run.py
Normal file
7
TaskD02/run.py
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
import re
|
||||||
|
import sys
|
||||||
|
|
||||||
|
for line in sys.stdin:
|
||||||
|
stripped_line = line.strip()
|
||||||
|
if re.search(r"\bpies\b", stripped_line, re.IGNORECASE):
|
||||||
|
print(stripped_line)
|
3
TaskD02/simple.out
Normal file
3
TaskD02/simple.out
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
Pies ma Alę
|
||||||
|
Kot i pies to zwierzęta
|
||||||
|
pies
|
7
TaskD03/run.py
Normal file
7
TaskD03/run.py
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
import re
|
||||||
|
import sys
|
||||||
|
|
||||||
|
for line in sys.stdin:
|
||||||
|
stripped_line = line.strip()
|
||||||
|
if re.search("19[0-9][0-9] r\.", stripped_line, re.IGNORECASE):
|
||||||
|
print(stripped_line)
|
3
TaskD03/simple.out
Normal file
3
TaskD03/simple.out
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
Kiedyś był 1934 r.
|
||||||
|
Kiedyś był 1934 r.fsdfsdfsdf
|
||||||
|
1934 r. to jakaś data
|
10
TaskD04/run.py
Normal file
10
TaskD04/run.py
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
import re
|
||||||
|
import sys
|
||||||
|
|
||||||
|
for line in sys.stdin:
|
||||||
|
stripped_line = line.strip()
|
||||||
|
if re.search("\d+", stripped_line):
|
||||||
|
sub = re.findall("\d+", stripped_line)
|
||||||
|
print(' '.join(sub))
|
||||||
|
|
||||||
|
|
4
TaskD04/simple.out
Normal file
4
TaskD04/simple.out
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
34234 34 5
|
||||||
|
34535
|
||||||
|
34
|
||||||
|
1992 1999
|
Loading…
Reference in New Issue
Block a user