Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. In general, in programming languages like C++, type of a variable is considered static semantics. True False 2. Which of the following can be

1. In general, in programming languages like C++, type of a variable is considered static semantics.

True

False

2.

Which of the following can be used to check correctness of a program

operational semantics

axiomatic semantics

Denotational semantics

None of these

3. In general, in programming languages like C++, value of a variable is considered static semantics.

True

False

4. Context free Grammars can be used for specifying static semantics

True

False

5. Select ALL Terminals in the following BNF rules: < ident_list > -> identifier | identifier, ? if then

identifier

,

if_stmt

then

stmt

ident_list

logic_expr

if

|

->

6. The following grammar IS ambiguous: -> + | const

True

False

7. What is the weakest precondition {P} for {P} x = 5y + 5 { x > 5}

y>2

x>2

x>5

y>0

x>0

y>5

8. Which of the following attributes are determined from nodes of children in parse tree

Inherited attributes

Intrinsic attributes

Synthesized attributes

None of these

9. Select all the valid preconditions {P} for

{P} x = y + 2 { y > 4}

x>2

x>4

x>0

x > -4

x>-2

y>5

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

AutoCAD Database Connectivity

Authors: Scott McFarlane

1st Edition

0766816400, 978-0766816404

More Books

Students also viewed these Databases questions

Question

=+a. Test for differences among the true average PAPUFA

Answered: 1 week ago

Question

What do these students reactions tell you about childrens thinking?

Answered: 1 week ago

Question

a. When did your ancestors come to the United States?

Answered: 1 week ago

Question

d. What language(s) did they speak?

Answered: 1 week ago

Question

e. What difficulties did they encounter?

Answered: 1 week ago