Module 2.10: BNF

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/16

flashcard set

Earn XP

Description and Tags

A set of vocabulary flashcards defining the Backus-Naur Form (BNF) syntax rules for a specific programming language grammar as provided in the lecture notes.

17 Terms

1
New cards

<letter>

a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | v | w | x | y | z

2
New cards

<digit>

0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9

3
New cards

<symbol>

_ | @ | . | ~ | ? | # | $

4
New cards

<char>

<letter> | <digit> | <symbol>

5
New cards

<operator>

+ | - | * | / | % | < | > | == | <= | >= | and | or | not

6
New cards

<identifier>

<letter> | <identifier><char>

7
New cards

<number>

<digit>|<number><digit>

8
New cards

<item>

<identifier> | <number>

9
New cards

<expression>

<item>| (<expression>) | <expression><operator><expression>

10
New cards

<branch>

if <expr>then {<block>} |

if <expr>then {<block>}else {<block>}

11
New cards

<switch>

switch<expr>{<sbody>}

12
New cards

<sbody>

<cases> | <cases>; default :<block>

13
New cards

<cases>

case<value>:<block> |

<cases> ; case<value>:<block>

14
New cards

<loop>

while <expr>do {<block>}

15
New cards

<assignment>

<identifier>=<expression>;

16
New cards

<statement>

<assignment> | <branch> | <loop>

17
New cards

<block>

<statement> | <block>;<statement>