AMCAT Programming Quiz-1

Question 1

Time: 00:00:00
Which of the following is not a valid variable name declaration?

float PI = 3.14

float PI = 3.14

double PI = 3.14

double PI = 3.14

#define PI = 3.14

#define PI = 3.14

Int PI = 3.14

Int PI = 3.14

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 2

Time: 00:00:00
Which of the following are visible global ?

Register

Register

Auto

Auto

Extern

Extern

Static

Static

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 3

Time: 00:00:00
What will happen if we use void when supplying arguments?

It won't give its caller anything back.

It won't give its caller anything back.

It will give its caller something of value.

It will give its caller something of value.

May or may not be dependent on the function's specified return type; the provided parameters differ from the return type of the function.

May or may not be dependent on the function's specified return type; the provided parameters differ from the return type of the function.

It will return a result.

It will return a result.

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 4

Time: 00:00:00
Which of the following pseudocode instructions are written with the steps to be taken in the correct order?

 

Sequence logic

Sequence logic

Selection logic

Selection logic

Iteration logic

Iteration logic

Looping logic

Looping logic

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 5

Time: 00:00:00
Which is used to convert source code to target language

linker

linker

compiler

compiler

loader

loader

executer

executer

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 6

Time: 00:00:00
How do references and pointers differ from one another?

Pointers store the address of a variable, whereas references serve as an alias for a variable.

Pointers store the address of a variable, whereas references serve as an alias for a variable.

Pointers and references are comparable.

Pointers and references are comparable.

A pointer points to a variable, whereas a reference holds the address of a variable.

A pointer points to a variable, whereas a reference holds the address of a variable.

While references maintain a variable's address, pointers serve as an alias for a variable.

While references maintain a variable's address, pointers serve as an alias for a variable.

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 7

Time: 00:00:00
Which of the following convert high-level language program into machine language program?

Compiler

Compiler

Translator

Translator

Both a and b

Both a and b

None of the option

None of the option

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 8

Time: 00:00:00
Which of the following how the location can be used?

 

 

attributes

attributes

data type

data type

links

links

Data objection

Data objection

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 9

Time: 00:00:00
what will be the value of sum of following code?
#include<iostream>
using namespace std;
int main(){
int i=1;
int j=0, sum=0;
while(i<=3){
j = (i+1)*(i-2);
sum = i + (j-1)*(j-2);
i++;

}
return 0;
}

9

9

8

8

10

10

15

15

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 10

Time: 00:00:00
What happens if the base condition in the recursion is not defined?

Stack underflow

Stack underflow

Stack Overflow

Stack Overflow

Empty Stack

Empty Stack

None

None

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

["0","40","60","80","100"]
["Need more practice!","Keep trying!","Not bad!","Good work!","Perfect!"]

Personalized Analytics only Availble for Logged in users

Analytics below shows your performance in various Mocks on PrepInsta

Your average Analytics for this Quiz

Rank

-

Percentile

0%

Completed

0/0

Accuracy

0%

Prime

Prime Video

Complete video course for AMCAT Sample Paper

For AMCAT
Prime Video

Prime

Prime Mock

Topic-wise full mocks based on AMCAT Sample Paper

For AMCAT
Prime Mock

Comments