HF RL Explorer

Task: Python Regex Pattern Matching - Return True if String Contains Pattern

Task: Python Regex Pattern Matching - Return True if String Contains Pattern: a task in Terminal-Lego-15k (Harbor dataset). Write a Python script that uses the re module to check whether a given string contains a substring matching a regular expression pattern. The script should implement a…

The task

Write a Python script that uses the `re` module to check whether a given string contains a substring matching a regular expression pattern. The script should implement a function that serves as a regex-based analog of Python's `'substring' in 'text'` operation.

Part of PrimeIntellect/Terminal-Lego-15k.