ACG ROUND-2 TECHNICAL QUIZ

ACG ROUND-2 TECHNICAL QUIZ

University

25 Qs

quiz-placeholder

Similar activities

Arrays and pointers quiz

Arrays and pointers quiz

University

20 Qs

C - Strings

C - Strings

University

20 Qs

Linux 3-4

Linux 3-4

University

20 Qs

Programming in C(1)

Programming in C(1)

University

20 Qs

CSI Coding Quiz

CSI Coding Quiz

University

20 Qs

OCS752_CP_MODEL 3_PART A

OCS752_CP_MODEL 3_PART A

University

30 Qs

2nd Class Test FEB 2021

2nd Class Test FEB 2021

University

25 Qs

PSC Quiz1

PSC Quiz1

University - Professional Development

20 Qs

ACG ROUND-2 TECHNICAL QUIZ

ACG ROUND-2 TECHNICAL QUIZ

Assessment

Quiz

Computers

University

Hard

Created by

Dr Reddy

Used 1+ times

FREE Resource

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.

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?