BNF Quiz

Beschreibung

Test your knowledge on BNF and EBNF
Amy Dang
Quiz von Amy Dang, aktualisiert more than 1 year ago
Amy Dang
Erstellt von Amy Dang vor mehr als ein Jahr
13
0

Zusammenfassung der Ressource

Frage 1

Frage
Define a grammar for the empty language, which is a language containing no strings. (There is no valid sentence in the empty language.)
Antworten
  • empty ->

Frage 2

Frage
Define a grammar for the letter language. A letter is a lower-case Latin letter between a and z.
Antworten
  • <letter> -> <a> | <b>| <c> | ... |<z>|

Frage 3

Frage
Define a grammar for the word language. A word is a sequence of one or more letters. You may refer to the letter nonterminal defined above.
Antworten
  • <word> -> <letter> |<word> <letter>

Frage 4

Frage
Define a grammar for the parenthesis language, where all sentences in the parenthesis language consist of balanced pairs of left and right parentheses. Example of valid pairs: (), (()), ()(), (((()())()())). Example of invalid pairs: ())(, (, )(, )(((((((((.
Antworten
  • <paren> -> (<paren>) <paren> | <empty>
Zusammenfassung anzeigen Zusammenfassung ausblenden

ähnlicher Inhalt

Welten im Kalten Krieg
andri.roth
Einstufungstest Italienisch Niveau B1.2
SprachschuleAktiv
Statistik und Differenzialgleichungen
barbara91
Bildungszitate
Laura Overhoff
ME2 Theorie
Matin Shah
Euro-FH // Zusammenfassung PEPS3
Robert Paul
Vetie - Histo & Embryo - P 2017
Fioras Hu
Histologie Schnitte Vetie
Kris Tina
Onlinequiz zu MS-4.2 kapitel II
Deborah Büscher
Vetie - Lebensmittel 2022
Ann Borg