Check Pattern Presence
Databricks interviews coding interview problem: You receive a digit string panel and an array of digit codes, where each code is a concatenation of an index and a pattern. For each code, try every split into index and pattern (both non-empty) and check if the pattern appears in panel at that index. Return an array with the pattern or "not found" for each code. A focused interview question.
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Input Variables
Execution Result:
