Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 2c7c10a

Browse files
files
1 parent e8a9afa commit 2c7c10a

File tree

2 files changed

+19
-4
lines changed

2 files changed

+19
-4
lines changed
Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
1-
import re
2-
for i in range(int(input())):
3-
email=input()
4-
print(bool(re.match(r"[A-Z]+ \<[A-Za-z-._]*\@[a-z]+\.[a-z]+{,3}\>",email)))
1+
import re
2+
for i in range(int(input())):
3+
c=input()
4+
if c=="{":
5+
while True:
6+
color=input()
7+
if color!="}":
8+
che=re.findall(r"(#[0-9a-fA-F]{6}|#[0-9a-fA-F]{3})",color)
9+
print(che)
10+
else:
11+
break
12+
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import re
2+
for i in range(int(input())):
3+
email=input()
4+
che=re.search(r"[A-Za-z]+ <[a-z0-9]+[a-z\._-]*[a-z0-9]+[@][a-z]+[.][a-z]{1,3}>$",email)
5+
if che:
6+
print(che.group())
7+

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /