forked from miczar1/djfz-24_25
Compare commits
No commits in common. "b718541d698b93aa7a9223ee755786dbf7cfec78" and "bcc3d7344f8336833dd87ab5f0bec97e67690a94" have entirely different histories.
b718541d69
...
bcc3d7344f
@ -1,10 +0,0 @@
|
|||||||
import regex as re
|
|
||||||
|
|
||||||
with open('shakespeare.in', encoding='utf8') as file:
|
|
||||||
lines = file.readlines()
|
|
||||||
pattern = re.compile(r'Hamlet')
|
|
||||||
for line in lines:
|
|
||||||
line = line.strip()
|
|
||||||
x = re.search(pattern, line)
|
|
||||||
if x:
|
|
||||||
print(line)
|
|
@ -1,10 +0,0 @@
|
|||||||
import regex as re
|
|
||||||
|
|
||||||
with open('polish_wiki_excerpt.in', encoding='utf8') as file:
|
|
||||||
lines = file.readlines()
|
|
||||||
pattern = r'( |[Pp])ies(( \w+)|(\.$))'
|
|
||||||
for line in lines:
|
|
||||||
line = line.strip()
|
|
||||||
x = re.search(pattern, line)
|
|
||||||
if x:
|
|
||||||
print(line)
|
|
File diff suppressed because one or more lines are too long
@ -1,10 +0,0 @@
|
|||||||
import re
|
|
||||||
|
|
||||||
with open('polish_wiki_excerpt.in', encoding='utf8') as file:
|
|
||||||
lines = file.readlines()
|
|
||||||
pattern = r'19\d\d r\.'
|
|
||||||
for line in lines:
|
|
||||||
line = line.strip()
|
|
||||||
x = re.search(pattern, line)
|
|
||||||
if x:
|
|
||||||
print(line)
|
|
File diff suppressed because one or more lines are too long
@ -1,10 +0,0 @@
|
|||||||
import re
|
|
||||||
|
|
||||||
with open('polish_wiki_excerpt.in', encoding='utf8') as file:
|
|
||||||
lines = file.readlines()
|
|
||||||
pattern = r'\d+'
|
|
||||||
for line in lines:
|
|
||||||
line = line.strip()
|
|
||||||
x = re.findall(pattern, line)
|
|
||||||
if x:
|
|
||||||
print(' '.join(x))
|
|
Loading…
Reference in New Issue
Block a user