CS6660 COMPILER DESIGN
UNIT 1
MULTIPLE CHOICE QUESTIONS
1.
Which code is known as machine code that is processed or executed by the processor?
A.
Source code
Object code
B.
C.
MSIL code
D.
Byte Code
2.
Low level language is also called as __________.
A.
B.
C.
D.
Machine language
Binary language
A and B are same
High level language
3.
Which programming language use symbolic codes called
MNEMONICS for developing the program?
A.
B.
Machine language
Low level language
C.
High level language
D.
Assembly language
4.
Which program allows text to be entered and changed?
A.
Editor
B.
C.
Translator
Compiler
D.
5.
Interpreter
Which program is known as translator , which read the whole code written in high level language at once and then convert it into machine language?
A.
Editor
B.
C.
Linker
Compiler
D.
Interpreter
6.
Which is a translator program, which read the code written in high level language line by line convert it into machine language?
A.
B.
C.
Linker
Editor
Compiler
D.
7.
Interpreter
Which program combine two or more object modules into a single object module or into an executable file?
A.
B.
Linker
Interpreter
C.
Assembler
D.
8.
Compiler
Which program is also called as loader?
A.
B.
Interpreter
Linker
C.
Javac
D.
9.
Compiler
A __________ is responsible for the task of collecting different modules of a skeletal source program.
A.
B.
linker loader
C.
preprocessor
D.
processor
10.
Which program is used to translates from low level language to higher one?
A.
Parse generator
B.
C.
Decompiler
Cross compiler
D.
Scanner
11.__________ accept the stream of character as input and produces stream of token as output.
A.
B.
Parser
Lexical analyzer
C. Scanner
D. B and C are same
12.
The sequences of character that give rise to token are called __________.
A.
B.
Intermediate code
Stream
C.
Lexemes
D.
Semantic
13.
The syntactical analyzer is also called __________.
A.
B.
lexemes parser
C.
lexical analyzer
D.
scanner
14.
What is refer to checking context dependent datatype?
A.
B.
Lexical analysis
Parser
C.
Semantic analysis
D.
Syntactical analyzer
15.
What is responsible to produce faster and smaller object program by performing some improvements over intermediate code?
A. Intermediate code generator
B.
C.
Code generator
Interpreter
D. Code optimizer
16.
What is responsible for generation of final machine code tailored to target system?
A.
B.
Interpreter
Semantic analyzer
C.
Code generator
D.
Code optimizer
17.
Which programming language use compiler as well as interpreter to produce output?
A.
B.
C language
C++
C.
Cobol
D.
Java
18.
Which data structure is used for book keeping?
A
B.
Lookup table
Symbol table
C.
Inode table
D.
Tree
19.
Which tool is used to construct compiler?
A.
B.
Compiler - Compiler
Compiler - generator
C.
NELIAC
D.
A and B is same
20.
the lexical analyzer produce tokens, which are stored in a buffer until they are consumed by the __________.
A.
B.
linker loader
C.
parser
D.
preprocessor
21.
What is called lexical analysis?
A.
Parallel analysis
B.
C.
Linear analysis
Parser
D.
Token
22.
Which operation is used for searching a lexical entry in the symbol table?
A.
B.
Insert
C.
Lookup
Select
D.
Scanner
23.
The additional information along with a token is called its
__________.
A.
B.
lexeme keyword
C.
attributes
D.
subset
24.
A lexical analyzer filter out __________ and __________.
A.
comment, keyword
B.
whitespace, comment
C.
D.
character, number operator, operand
25.
Token refer to a set of __________.
A.
string keyword
B.
C.
D.
pattern lexem
Both Logical and Syntax Error
Not Logical and Syntax Error
27.An intermediate code form is
A.
B.
C.
D.
postfix notation syntax trees three address codes all of these
A.
B.
C.
D.
28.Three address code invloves exactly 3 address at the most 3 address no unary operators none of these
26.
Compiler can check?
Logical Error
Syntax Error