Search⌘ K
AI Features

Exercise: Balanced Brackets

Explore how to determine if strings containing square brackets are balanced using loops. Understand the logical approach to matching opening and closing brackets, and practice implementing the check_balance() function that returns accurate results for various inputs.

Problem statement

Given a string containing only ...