jaVer404

Bank_spliter

Jun 29th, 2024
685
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.35 KB | None | 0 0
  1. def has_matching_fourth_line(pages):
  2.     # Регулярний вираз для перевірки
  3.     pattern = re.compile(r'^.*".*".*$')
  4.  
  5.     for page in pages:
  6.         lines = page.splitlines()
  7.         if len(lines) >= 4 and pattern.match(lines[3]):
  8.             print (lines[3])
  9.             #return True
  10.         #else:
  11.             #return False
Advertisement
Add Comment
Please, Sign In to add comment