Professional KnowledgeHardIBPS SO IT

Which of these is a context-free but not a regular language?

  1. A. Strings with an even number of 0s
  2. B. Balanced parentheses
  3. C. a*b*
  4. D. All binary strings

Correct answer: B. Balanced parentheses

Balanced parentheses need unbounded memory.

More IT Officer Professional Knowledge (IBPS SO) questions

Exams that ask this topic