Datadog interview question

String pattern matching based easy qn