
ACG ROUND-2 TECHNICAL QUIZ
Authored by Dr Reddy
Computers
University
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
25 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Which of the following highly uses the concept of an array?
Binary Search Tree
Caching
Spatial Locality
Process Scheduling
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the value retuned by the following function, when it is called with a value 11?
int recur(int num)
{
if ( ( num/2) !=0 )
return ( recur(num/2 ) * 10+num%2 );
else return 1;
}
Function does not return any value, because it goes into an infinite loop
11
1011
None
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Consider the following program fragment.
static char wer[3][4] = {"bag", "let", "bud"};
char(*ptr)[4] = wer;
In which of the following cases will the character 't' be printed?
putchar ( ( (ptr+1) + 2));
putchar ( * (wer [1] + 2) ) ;
putchar (* (ptr+1) + 2);
None
4.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Consider the two declarations
void *voidPtr;
char *charPtr;
Which of the following assignments are syntactically correct?
voidPtr = charPtr
charPtr = voidPtr
*voidPtr = *charPtr
*charPtr = voidPtr
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What does the following fragment of C-program print?
char c[ ] = “GATE2011”;
char *p = c;
printf(“%s”, p + p[3] – p[1]);
GATE 2011
E2011
2011
01
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What does the following program print?
#include < stdio.h >
void f (int p, int q) {
p = q;
*p = 2;
}
int i = 0, j = 1;
int main ( ){
f(&i, &j);
printf (“%d %d \ n”, i, j);
return 0;
}
2 2
2 1
0 1
0 2
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What does the following C statement declare?
int (*f)(int *);
A function that take an integer pointer as an argument and returns an integer.
A function that take integer as an argument and return an integer pointer.
A pointer to a function that takes an integer pointer as an argument and return an integer.
A function that take an integer pointer as an argument and return a function pointer.
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?