
Pointers_Structures
Quiz
•
Computers
•
University
•
Medium
ALDO STALIN J L
Used 1+ times
FREE Resource
Enhance your content in a minute
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
In a C Program if
int a = 5;
Int *ptr = &a;
then the printf statement with
&a, a, *ptr , ptr
adrress, Value, Value, Adress
address, value, value, value
all address
All values
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
If ptr is a pointer variable pointing to an array, then
"printf("%d",*(ptr++)) ;"
statement will print :
Next location address
Next location index value
Next location value
Compile time error
3.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
What will be output?
int i=10;
int *p;
p=&i;
i+=5;
printf("\n i=%d *p=%d", i,*p)
i=10, *p=10
i=10, *p=15
i=15, *p=15
i=15, *p=10
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Code to change the 3rd array value to 50 using pointers
int main(){
int a[] = {10,20,30};
int *p = a;
----------------------;
}
p+3 = 50
*(p+3) = 50
*p+2 = 50
*(p+2) = 50
5.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
1. Prior to using a pointer variable it should be
Declared
Initialized
Both declared and initialized
None of these
6.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What is the output of C program with arrays and pointers.?
int main()
{
int a[3] = {20,30,40};
printf("%d", *(a+1));
}
20
30
40
Compiler error
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
If a variable is a pointer to a structure, then which of the following operator is used to access data members of the structure through the pointer variable?
.
&
*
->
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?
Similar Resources on Wayground
20 questions
Web Designing Quiz-1
Quiz
•
University
20 questions
POO_BasicoyJava
Quiz
•
University
15 questions
Uji Pengetahuan TIK untuk Siswa Kelas 9
Quiz
•
9th Grade - University
15 questions
8051-MCQ
Quiz
•
University
20 questions
Control Structures C#
Quiz
•
University
15 questions
Introducción a CNC
Quiz
•
University
15 questions
BASIC C QUIZ
Quiz
•
University
20 questions
ทดสอบย่อย 3 หลักการเขียนโปรแกรม
Quiz
•
University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
