Quiz%201_03 - <id> → A | B | C <expr> →...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
ICS 313-03 (022) Quiz # 1 Weight 3% 15 March, 2003 Q. 1 [5 points]: Identify the different aspects of the cost of a programming language. Q. 2 [5 points]: What features of SIMULA 67 are now important parts of most recent languages. ID: ___________ Name: _____________________
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Q. 3 [5 points]: Consider the following BNF definition of simple assignment statements: <assign> <id> = <expr>
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: <id> → A | B | C <expr> → <expr> + <term> | <term> <term> → <term> * <factor> | <factor> <factor> → ( <expr> ) | <id> Create a leftmost derivation to show that the following string is a legal assignment statement: B = A * (B + (A * C)) Q. 4 [5 points]: Prove that the following grammar is ambiguous: <S> → <A> <A> → <A> + <A> | <id> <id> → a | b| c...
View Full Document

This note was uploaded on 09/15/2010 for the course ICS ics103 taught by Professor Alvi during the Spring '07 term at King Fahd University of Petroleum & Minerals.

Page1 / 2

Quiz%201_03 - <id> → A | B | C <expr> →...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online