Posted on May 30, 2012September 30, 2016 by arvifox Bracket sequence ()((())((()) Is it correct sequence? I need just a counter. foreach char in string { If next bracket is “(” then inc(counter); If next bracket is “)” then dec(counter); If counter < 0 then showmessage(“Error”); } Post navigationPrevious post: delphi key stateNext post: If 0 then print 0 else 1