OODP FT1

OODP FT1

University

30 Qs

quiz-placeholder

Similar activities

Arrays and Strings in C

Arrays and Strings in C

12th Grade - University

32 Qs

DSA - Q1

DSA - Q1

University

25 Qs

Quiz Bahasa C

Quiz Bahasa C

10th Grade - University

25 Qs

Curse Breakers Quiz

Curse Breakers Quiz

University

25 Qs

Code Chase Round-1

Code Chase Round-1

University

30 Qs

Round_1 (B)| Coding Combat 2.0

Round_1 (B)| Coding Combat 2.0

University

30 Qs

TECH_IQ_HUNT ROUND

TECH_IQ_HUNT ROUND

University

25 Qs

Basic programming

Basic programming

University

30 Qs

OODP FT1

OODP FT1

Assessment

Quiz

Computers

University

Medium

Created by

Preethi V

Used 3+ times

FREE Resource

30 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Guess the output of the following code:

#include<stdio.h>

int main() {

char str[]="Hello"

char *ptr=str;

ptr+=3;

printf("%s", ptr);

return 0;

}

Hello

lo

Hel

llo

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

what's wrong with this code?

#include<stdio.h>

void main() {

int n=5;

int arr[n];

for(int i=1;i<=n; i++)

arr[i] = i;

printf("%d",arr[n]);

}

Variable-sized array declaration

Array index out of bound

Missing return statement

All of these

3.

FILL IN THE BLANK QUESTION

1 min • 1 pt

Operator in pointer is referred as

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

this code will give the output as -----------

#include<stdio.h>

int main(){

int i = 1;

do{

printf("%d",i);

i++;

if(i>3) break;

} while(1);

return 0;

}

123

12

1234

12345

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

An array is a collection of

different data types scattered throughout memory

the same data type scattered throughout memory

the same data type placed next to each other in memory

different data types placed next to each other in memory

6.

FILL IN THE BLANK QUESTION

1 min • 1 pt

find the output of the following code:

#include<stdio.h>

int main()

{

int x=15;

printf("\n%d%d",x<30,x=20);

}

7.

FILL IN THE BLANK QUESTION

1 min • 1 pt

correct the following code:

int main()

{

int tag = 0,code = 1;

if(tag==0)

(code>1? printf("\nHello")? printf("\nHi"));

else

printf("\nHello Hi ! ! ");

}

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?