← Sprinklr questions
CodingReported in a candidate post, Aug 2021

Count beautiful contiguous substrings with wildcards

Filed under Sprinklr

The question

Given a string consisting of 0, 1, and ?, where a string is unstable if adjacent characters differ and beautiful if wildcards can be replaced to make it unstable, calculate the number of beautiful contiguous substrings.

No write-up yet. Related questions below have one.

Related Sprinklr questions

Collected from public candidate posts and coding forums. Updated Nov 2026.