
programming in c pointers
Quiz
•
Science
•
Professional Development
•
Medium
Prajakta Bhadale
Used 3+ times
FREE Resource
Enhance your content
11 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
_____is a variable that stores memory address of another variable which is of similar data type.
node
array
pointer
string
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
datatype *pointer_variable_name;
array syntax
string syntax
pointer syntax
c syntax
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
pointer arithmetic operations...?
1.Increment
2.Decrement
3.Addition
4.Subtraction
1.multiplication
2.division
3.modular
1.Iogical AND
2.logical OR
any other
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
void main()
{
int a[5],sum=0,i,*ptr;
clrscr();
printf("\n Enter array elements:");
for(i=0;i<5;i++){
scanf("%d",&a[i]);
ptr=&a[0];
}
for(i=0;i<5;i++) {
sum=sum+(*ptr); ptr=ptr+1;
} printf("\n Sum= %d",sum);
getch();
}
ABOVE CODE IS OF.....?
C program to sum of all elements stored in given array
C program to sum of all elements
C program to sum of all elements stored in given array using pointer
C program to sum
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
datatype pointer_variable_name;
Eg: int ptr;
Array
Variable
string
pointer
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
void main() {
int x,y,a, b,*P1, P2;
x = 10; y = 20;
P1 = &x;
P2 = &y;
a = P1 * P2 +20;
b = P1 * *P2 – 20;
print f(“x=%d, y = %d”, x,y);
print f(“a=%d, b = %d”, a,b);
}
output for the above code is.....?
Output: x=15, y=10a=20, b=80
Output: x=20, y=10a=22, b=18
Output: x=10, y=20a=220, b=180
error
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Explain meaning of following statements with reference to pointers
int a, b ; b = 20 ; a= b ; a = &b ;
no idea
int a,b; It is declaration of integer pointer a and integer variable b=20; value 20 is assigned to variable b. a=b; Value of b is assigned to pointer a. A=&b; Address of b is assigned to variable A.
int a,b; It is declaration of pointer a and integer variable b b=20; value 20 is assigned to variable b. a=b; Value of b is assigned to pointer a. A=&b; Address of a is assigned to variable A.
int a,b; It is declaration of integer pointer a and integer variable b b=20; value 20 is assigned to variable b. a=b; Value of b is assigned to pointer a. A=&b; Address of a is assigned to variable b.
Create a free account and access millions of resources
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
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?
Similar Resources on Wayground
10 questions
ABA 102
Quiz
•
Professional Development
10 questions
DOCENCIA Y EDUCACIÓN PARA LA SALUD
Quiz
•
Professional Development
10 questions
基本電學第一章(電阻種類及特性 續)
Quiz
•
Professional Development
12 questions
Integrated Technics Ramadan Competition
Quiz
•
Professional Development
9 questions
Apartados iniciales anteproyecto
Quiz
•
University - Professi...
10 questions
GK Quiz 5
Quiz
•
6th Grade - Professio...
10 questions
Design of Experiments
Quiz
•
Professional Development
12 questions
Scientific method
Quiz
•
KG - Professional Dev...
Popular Resources on Wayground
20 questions
Brand Labels
Quiz
•
5th - 12th Grade
10 questions
Ice Breaker Trivia: Food from Around the World
Quiz
•
3rd - 12th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
20 questions
ELA Advisory Review
Quiz
•
7th Grade
15 questions
Subtracting Integers
Quiz
•
7th Grade
22 questions
Adding Integers
Quiz
•
6th Grade
10 questions
Multiplication and Division Unknowns
Quiz
•
3rd Grade
10 questions
Exploring Digital Citizenship Essentials
Interactive video
•
6th - 10th Grade