Problems
Contests
Account
Problems
> Count the Transitions > Editorial
Count the Transitions — Solution & Editorial
Back to the Problem
Compare each character with its predecessor.
Complexity:
O(|S|)
×
Refer Job