Sponsored
Sponsored
Use these hints if you're stuck. Try solving on your own first.
Iterate through each character, while maintaining whether we are currently between a pair of ‘|’ or not.
If we are not in between a pair of ‘|’ and there is a ‘*’, increment the answer by 1.