You are viewing a single comment's thread. Return to all comments →
This is my code for this problem , i used Pypy 3 instead of Python 3. Below is my code
import sys import re lista = [] for line in sys.stdin: if(line != ''): lista.append(line.rstrip()) for i in range(int(lista[0])): try: re.compile(lista[i+1]) is_valid = True print('True') except re.error: is_valid = False print('False')
Seems like cookies are disabled on this browser, please enable them to open this website
Incorrect Regex
You are viewing a single comment's thread. Return to all comments →
This is my code for this problem , i used Pypy 3 instead of Python 3. Below is my code