Questions 11–20 of 55. Imported answers require independent review unless marked reviewed.

Topic practice 55 questionsPage 2 of 6

Question 22

Open question
CSMCQ1 markNeeds review
Given the following syntax directed translation rules:
Rule 1:

Rule 2:

Rule 3:

Which ONE is the CORRECT option among the following?
Your answerChoose one option.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 40

Open question
CSMCQ2 marksNeeds review
Given a Context-Free Grammar

as follows:


Which ONE of the following statements is TRUE?
Your answerChoose one option.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 46

Open question
CSMSQ2 marksNeeds review
Which of the following statement(s) is/are TRUE while computing First and Follow during top down parsing by a compiler?
Your answerSelect all correct options. You can choose more than one.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 51

Open question
CSMSQ2 marksNeeds review
Consider two grammars

and

with the production rules given below:





where

,

,

,

,

,

are the terminals.
Which of the following option(s) is/are CORRECT?
Your answerSelect all correct options. You can choose more than one.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 52

Open question
CSNAT2 marksNeeds review
Refer to the given 3-address code sequence. This code sequence is split into basic blocks. The number of basic blocks is _______. (Answer in integer)
1001: i = 1 1002: j = 1 1003: t1 = 10i 1004: t2 = t1+j 1005: t3 = 8t2 1006: t4 = t3-88 1007: a[t4] = 0.0 1008: j = j+1 1009: if j<= 10 goto 1003 1010: i = i+1 1011: if i <= 10 goto 1002 1012: i = 1 1013: t5 = i-1 1014: t6 = 88*t5 1015: a[t6] = 1.0 1016: i = i+1 1017: if i <= 10 goto 1013

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 21

Open question
CSMCQ1 markNeeds review
Consider the following two sets:
Set X P. Lexical Analyzer Q. Syntax Analyzer R. Intermediate Code Generator S. Code Optimizer
Set Y
Abstract Syntax Tree
Token
Parse Tree
Constant Folding
Which one of the following options is the CORRECT match from Set X to Set Y?
Your answerChoose one option.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 26

Open question
CS1MSQ1 markNeeds review
Which of the following is/are Bottom-Up Parser(s)?
Your answerSelect all correct options. You can choose more than one.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 29

Open question
CSMSQ1 markNeeds review
Which of the following statements is/are FALSE?
Your answerSelect all correct options. You can choose more than one.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 37

Open question
CS1MCQ2 marksNeeds review
Consider the following syntax-directed definition (SDD).
Production
Semantic rule
















Give "MLK" as the input, which one of the following options is the CORRECT value computed by the SD (in the attribute

)?
Your answerChoose one option.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer

Question 39

Open question
CS1MCQ2 marksNeeds review
Consider the following pseudo-code.

Which one of the following options CORRECTLY specifies the number of basic blocks and the number of instructions in the largest basic block, respectively?
Your answerChoose one option.

Log in to check the answer

You can attempt this question now. Sign in to view the answer key, explanations and discussion.Log in to check answer