1) What is Formal Language? a) A language used in everyday conversation b) A language based on a set of rules and symbols for computation or logic c) A programming slang used by developers d) A dialect used for formal writing 2) One example of Formal Language is: a) English b) Malay c) Java syntax d) Arabic 3) What is Natural Language? a) A machine-generated coding syntax b) A language that follows strict grammatical rules c) A human language used for communication d) A mathematical notation 4) One example of Natural Language: a) C++ b) Regular Expressions c) English d) HTML 5) How do we represent Finite State Machine? a) With conditional statements b) Using flowcharts only c) Through state diagrams or transition tables d) Using natural language statements 6) How do we represent an accepting state in a finite state diagram? a) A dashed circle b) A rectangle c) A double circle d) A triangle 7) What are the three operations we can do on Regular Expressions? a) Union, Intersection, Subtraction b) Union, Concatenation, Kleene star c) Addition, Subtraction, Multiplication d) Selection, Repetition, Assignment 8) List the precedence of Regular Expression operations (from highest to lowest): a) Union > Concatenation > Kleene star b) Concatenation > Kleene star > Union c) Kleene star > Concatenation > Union d) Kleene star > Union > Concatenation

CSC569 Chapter 3 - Lexical Analysis & Scanner Generator

Leaderboard

Visual style

Options

Switch template

Continue editing: ?