100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.6 TrustPilot
logo-home
Exam (elaborations)

CS 326 Final Exam

Rating
-
Sold
-
Pages
7
Grade
A+
Uploaded on
10-08-2025
Written in
2025/2026

CS 326 Final Exam finite automata: chars go into a lexer to make tokens CFG/PDA: tokens go into parser to make AST these then do other stuff - answersWhat is the lexer parser diagram? Any arbitrary program fed to, lets call an analyzer, can it, with infinite memory and speed, determine if the arbitrary program will stop sometime in the future? - answersWhat is the halting problem? Symmetry in language design. - answersWhat is orthogonality? statically typed and dynamically typed. - answersWhat are the two language "types"? <assign> -> <var> = <expression> - answersWhat is Backus-Naur Form? The process of breaking up symbols, typically text, into tokens. - answersWhat is lexing? True - answersT/F. Regular grammars are finite automata. - answersexcercise: derive and parse tree <program> —> begin <stmt_list> end <stmt_list> <stmt> I <stmt> ; <stmt_list> <stmt> —><var>=<expression> <var>—>A I B I C <expression> —> <var> + <var> | <var> - <var> | <var> - answersexcercise: derive and parse tree

Show more Read less
Institution
Cs 326
Course
Cs 326









Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Institution
Cs 326
Course
Cs 326

Document information

Uploaded on
August 10, 2025
Number of pages
7
Written in
2025/2026
Type
Exam (elaborations)
Contains
Questions & answers

Content preview

CS 326 Final Exam
finite automata: chars go into a lexer to make tokens

CFG/PDA: tokens go into parser to make AST

these then do other stuff - answers✔✔What is the lexer parser diagram?



Any arbitrary program fed to, lets call an analyzer, can it, with infinite memory and speed, determine if
the arbitrary program will stop sometime in the future? - answers✔✔What is the halting problem?



Symmetry in language design. - answers✔✔What is orthogonality?



statically typed and dynamically typed. - answers✔✔What are the two language "types"?



<assign> -> <var> = <expression> - answers✔✔What is Backus-Naur Form?



The process of breaking up symbols, typically text, into tokens. - answers✔✔What is lexing?



True - answers✔✔T/F. Regular grammars are finite automata.



- answers✔✔excercise: derive and parse tree



<program> —> begin <stmt_list> end

<stmt_list> <stmt> I <stmt> ; <stmt_list>

<stmt> —><var>=<expression>

<var>—>A I B I C

<expression> —> <var> + <var> | <var> - <var> | <var>



- answers✔✔excercise: derive and parse tree

, <assign> -> <id> = <expr>

<id> -> A | B | C

<expr> -> <id> + <expr>

| <id> * <expr>

| (<expr>)

| <id>



When one input can produce two different outputs, i.e. parse trees. - answers✔✔What is ambiguity?



No, it is impossible to prove a grammar is not ambiguous, but one can prove a grammar is ambiguous by
finding an example. - answers✔✔Can you prove a grammar is not ambiguous?



LL: left to right, left-most derivation with no look ahead. - answers✔✔Define LL generator



GLR: generalized left-to-right. right-most derivation and handles some ambiguity. - answers✔✔Define
GLR generator



Adaptive LL*: allows some ambiguity in certain parts. Balances flexibility and speed. - answers✔✔Define
Adaptive LL* generator



Allows optional conditionals in grammar writing and recursion.

e -> (+ | -) term | term

T -> T [+ T] - answers✔✔What is EBNF?



e -> e (+ | -) term | term

term -> term (* | /) factor | factor

factor -> factor ^ exponent | id

exponent -> id
$8.49
Get access to the full document:

100% satisfaction guarantee
Immediately available after payment
Both online and in PDF
No strings attached

Get to know the seller
Seller avatar
newborn

Also available in package deal

Thumbnail
Package deal
cs-326 quizlet with questions and answers
-
2 2025
$ 16.98 More info

Get to know the seller

Seller avatar
newborn stuvia
View profile
Follow You need to be logged in order to follow users or courses
Sold
0
Member since
5 months
Number of followers
0
Documents
197
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Frequently asked questions