Explore topic-wise MCQs in Mechanical Engineering.

This section includes 199 Mcqs, each offering curated multiple-choice questions to sharpen your Mechanical Engineering knowledge and support exam preparation. Choose a topic below to get started.

1.

What will be the output of the following code?int main() { char ch; ch=129; printf("%d\n",ch); return 0; }

A. 129
B. -129
C. -127
D. syntax error
Answer» D. syntax error
2.

Any manipulation on the formal parameters doesn’t have effect on values in activation of the_____.

A. caller
B. callee
C. call
D. value
Answer» B. callee
3.

exception handling is for….

A. handling run time error
B. handling syntax error
C. handling logical error
D. all of these
Answer» B. handling syntax error
4.

…………………..defines the meaning of the program.

A. algebric semantic
B. axiomatic semantics
C. denotational semantic
D. translation semantics
Answer» C. denotational semantic
5.

………………….hints at characteristics of language , which are related to language user.

A. syntax
B. semantics
C. pragmatic
D. rules
Answer» C. pragmatic
6.

choose the correct? I)procedure is a kind of routine that return a value? II)functio is a kind of routine that dose no return any value?

A. only one
B. only two
C. both i&ii
D. none of these
Answer» E.
7.

The syntax of language id define by two sets…

A. lexical rules
B. syntactic rules
C. both a & b
D. none of this
Answer» D. none of this
8.

Which of the following logic is used to produce loops in programme logic?1)A data object that is characterized and named unequivocally in a program is named as…………...

A. value.
B. variables.
C. name.
D. scope.
Answer» C. name.
9.

What will be the output of the following code? #include using namespace std; int main() { float a='a'; cout<

A. a
B. 0.0
C. 97
D. syntax error
Answer» D. syntax error
10.

…………………means combine available symbol to create well formed sentences in the language

A. semantics
B. syntax
C. both a & b
D. none of above
Answer» C. both a & b
11.

A strict type system in which one operand type A is allowed to perform operation with another operand with type B.This feature of type system is called _____________.

A. type compatibility
B. type equivalence
C. type conformance
D. all of these
Answer» E.
12.

If you don’t specify a mode for a parameter, what is the default mode?

A. out
B. in
C. copy
D. none
Answer» C. copy
13.

A strict substitution is called ‘in-line expansion’or_________.

A. macro extension
B. local function
C. both a & b
D. none of these
Answer» B. local function
14.

which of the not looping statement in c?

A. while
B. until
C. double
D. for
Answer» C. double
15.

The address of actual parameter is passed to the formal parameter, “______”can happen.

A. overloading
B. aliasing
C. caller
D. none of these
Answer» C. caller
16.

The scope of a variable declared as static storage class is__________

A. local within the function declared
B. in multiple programs
C. global
D. none of the above
Answer» B. in multiple programs
17.

__________binding is used to define the scope in terms of the lexical structure of a program.

A. static scope.
B. dynamic scope.
C. both
D. none of these
Answer» B. dynamic scope.
18.

The function with the name ___________ is always written in every program

A. int
B. main
C. void
D. factorial
Answer» C. void
19.

The scope of a variable declared externally, is__________

A. local within the function declared
B. global
C. in multiple programs
D. none of the above
Answer» D. none of the above
20.

The time amid program formulation or processing when this decision is made is named........

A. binding period
B. binding cycle
C. binding time
D. none
Answer» D. none
21.

Which of the following logic is used to produce loops in programme logic?1)A data object that is characterized and named unequivocally in a program is named as…………...

A. value.
B. variables.
C.   name.
D. scope.
Answer» C.   name.
22.

Binding is chosen by .......

A. programmer
B. loader
C. translator
D. all of above
Answer» E.
23.

Execution time binding is also called as

A. run time bindind
B. both
C. early binding
D. none
Answer» D. none
24.

Binding is done at_ _ _

A. translation time
B. execution time
C. both a) & b)
D. none
Answer» C. both a) & b)
25.

which of the following are language processors

A. assembler
B. compilers
C. interpreter
D. all of these
Answer» B. compilers
26.

disadvantage of compiler and go loading scheme is that

A. a position of memory is wasted because the case occupied by the assembler is unavailable the object program
B. it is necessary to retranslate the users program check every time it is run
C. it is very difficult to handle multiple segments especially if the source programs are in different language and to produce overlay modular programs
D. all of the above
Answer» E.
27.

An assembler converts

A. machine code to mnemonics
B. high level language to assembly level
C. assembly language to machine language
D. all of the above
Answer» D. all of the above
28.

An interpreter is a program that

A. places programs into memory and prepares then for execution
B. automates the translation of assemble language into machine language
C. accepts a program written in a high level language and produces an object program
D. appears to execute a resource as if it were machine language
Answer» C. accepts a program written in a high level language and produces an object program
29.

Numerous binding are performed amid program execution is called_ _ _ _

A. run time binding
B. late binding
C. both a) & b)
D. early binding
Answer» D. early binding
30.

Which is not a funciton of a loader

A. allocation
B. translation
C. relocation
D. loading
Answer» C. relocation
31.

An assembler is

A. programming language dependent.
B. syntax dependant.
C. machine dependant.
D. data dependant.
Answer» D. data dependant.
32.

Which of the following can be used as a criterion for classification of data structures used in language processing.

A. nature of a data structure
B. purpose of a data structure
C. lifetime of a data structure
D. all of the above
Answer» E.
33.

The translator which perform macro expansion is called a

A. macro processor
B. macro pre-processor
C. micro pre-processor
D. assembler
Answer» C. micro pre-processor
34.

Self modifying code can be easily implemented by

A. interpreter
B. compiler
C. both
D. none
Answer» B. compiler
35.

Translator for low level programming language were termed as C

A. assembler
B. compiler
C. linker
D. loader
Answer» B. compiler
36.

In computing , an interpreter is a computer that reads the source code of another program and execute that program

A. true
B. false
Answer» B. false
37.

In ------- Higher level language is converted into lower level lenguage

A. interpreter
B. compiler
C. both
D. none
Answer» B. compiler
38.

In interpreter memory required is?

A. less
B. more
C. average
D. none
Answer» B. more
39.

In interpreter conditional control statements are execute slower

A. true
B. false
Answer» B. false
40.

BASIC language is an example of:

A. interpreter
B. compiler
C. both
D. none
Answer» B. compiler
41.

No intermediate code is generated in

A. interpreter
B. compiler
C. both
D. none
Answer» B. compiler
42.

Interpreters are frequently used to executed

A. commad language
B. glue language
C. both
D. none
Answer» D. none
43.

____translate code into some efficient ntermesiate representation and immediately execute that.

A. translator
B. interpreter
C. compiler
D. none of the above
Answer» C. compiler
44.

CPU is also an interpreter of machine instruction

A. true
B. false
Answer» B. false
45.

An interpreter is a program that repetitively executes :

A. get the next statement
B. determine the action to be executed
C. perform the action
D. all of the above
Answer» D. all of the above
46.

The control link of activation record points to__________.

A. caller procedure
B. callee procedure
C. both a & b
D. none of these
Answer» B. callee procedure
47.

______field ,of activation record refers to non local data in another activation record .

A. actual parameters
B. access link
C. control link
D. return values
Answer» C. control link
48.

The root of activation tree represents_________.

A. main program
B. called procedure
C. a and b
D. none of these
Answer» D. none of these
49.

The node of activation tree represents___________.

A. main
B. procedure
C. a and b
D. none of these
Answer» D. none of these
50.

The hybid method between call by value and call by reference is______.

A. call by name
B. copy restore
C. call by address
D. none of these
Answer» C. call by address