"For every success of a man there will be a countless pain in his heart and that pain makes him a successful person in life"

When You are at the Peak of Concentration, You don't feel whether u r programming in C/C#/JAVA or any other, You just type the keys on keyboard and your sub-conscious mind does the rest...!

Myspace GlittersMyspace GlittersMyspace GlittersMyspace GlittersMyspace GlittersMyspace GlittersMyspace GlittersMyspace Glitters




 
   

C - Pointers

   
 


 

 

Home

Guestbook

GALLERY

MySQL

C/C++ Interview Questions

C/C++ Test Paper 1

C/C++ Test Paper 2

C Tricky Snippets

C - Pointers

C - Functions

C - Iterations, Operators

Java Interview Questions

Java Fundamentals

Java FAQs

J2EE - FAQs

Java - Best Collection Ever

Java/J2EE Test 1

Java Test 2

Java Servlets - FAQs

SCJP 5.0 Syllabus

SCJP Exam 1

SCJP Exam 2

SCJP Exam 3

SCJP Exam 4

SCJP Exam 5

Relational Database Management Systems(RDBMS) Imp. Concepts

SQL Server - Interview Questions

SQL Server 2

Data Structures

OOPS - FAQs

Object Oriented Programming (OOP) Concepts

Operating Systems - FAQs

Operating System Concepts

Networking Concepts

UML - Quick Reference

VB - FAQs

Secrets About Windows Operating Systems

 


     
 

Pointers - Part I
[Q001] Several declarations involving pointers are shown below. Pick the correct solution.
int *ptr;
 (a)ptr is a integer variable
 (b)ptr is a pointer to an integer quantity
 (c)Invalid statement
 (d)None of these
  
 
  [Q002] Several declarations involving pointers are shown below. Pick the correct solution.
  int *ptr[10];
  (a)ptr is a pointer to an integer quantity
  (b)ptr is a pointer to a 10-element integer array
  (c)ptr is a 10-element array of pointers to integer quantities
  (d)None of these
  
 
[Q003] Several declarations involving pointers are shown below. Pick the correct solution.
int (*ptr)[10];
  (a)ptr is a pointer to an integer quantity
 (b)ptr is a pointer to a 10-element integer array
 (c)ptr is a 10-element array of pointers to integer quantities
 (d)None of these
 
[Q004] Several declarations involving pointers are shown below. Pick the correct solution.
 int *ptr(void);   
 (a)ptr is a pointer to an integer
 (b)ptr is a function that returns a pointer to an integer quantity
 (c)ptr is a function pointer that returns integer quantity
 (d)None of these
 
[Q005] Several declarations involving pointers are shown below. Pick the correct solution.
int ptr(int *a);
 (a)Invalid statement
 (b)ptr is a function that accepts an argument which is a pointer to a integer returns an integer quantity
 (c)ptr is a function pointer
 (d)None of these
 
 [Q006] Several declarations involving pointers are shown below. Pick the correct solution.  
int *ptr(int *a);
(a)Invalid statement
 (b)ptr is a function pointer that accepts an argument which is a pointer to a integer returns an integer quantity
 (c)ptr is a function that accepts an argument which is a pointer to a integer returns a pointer to an integer quantity
 (d)None of these
  
 
[Q007] Several declarations involving pointers are shown below. Pick the correct solution.
int (*ptr)(char *a);
  (a)Invalid statement
 (b)ptr is a pointer to a function that accepts an argument which is a pointer to a character returns an integer quantity
 (c)ptr is a function that accepts an argument which is a pointer to a character returns a pointer to an integer quantity
 (d)None of these
 
 [Q008] Several declarations involving pointers are shown below. Pick the correct solution. 
int (*ptr(int *b))[5];
(a)Invalid statement
 (b)ptr is a pointer to a function that accepts pointer to an integer returns a 5-element integer array
 (c)ptr is a function that accepts an argument which is a pointer to a integer returns a pointer to a 5-element integer array
 (d)None of these 
 
 [Q009] Several declarations involving pointers are shown below. Pick the correct solution.
 char ptr(int (*a)[]);
(a)Invalid statement
 (b)ptr is a function that accepts an argument which is a pointer to a integer array returns an character quantity
 (c)ptr is a function that accepts an argument which is an array of pointers to integers returns an character quantity
 (d)None of these
  
 
[Q010] Several declarations involving pointers are shown below. Pick the correct solution.
char ptr(int *a[]);
 
  (a)Invalid statement
 (b)ptr is a function that accepts an argument which is a pointer to a integer array returns an character quantity
 (c)ptr is a function that accepts an argument which is an array of  pointers to integers returns an character quantity
 (d)None of these
 
[Q011] Several declarations involving pointers are shown below. Pick the correct solution.
int *ptr(char a[]);
(a)ptr is a function pointer
 (b)ptr is a function that accepts an argument which is a character array returns an integer
 (c)ptr is a function that accepts an argument which is a character array returns a pointer to an integer quantity
 (d)None of these
 
 
 [Q012] Several declarations involving pointers are shown below. Pick the correct solution.
 int *ptr(char *a[]); 
(a)ptr is a function pointer
 (b)ptr is a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (c)ptr is a function that accepts an argument which is a array of pointers to characters returns a pointer to an integer quantity
 (d)None of these
 
 
 [Q013] Several declarations involving pointers are shown below. Pick the correct solution.
int (*ptr)(char (*a)[]); 
 (a)ptr is a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (b)ptr is a pointer to a function that accepts an argument which is a pointer to a character array returns an integer quantity
 (c)ptr is a pointer to a function that accepts an argument which is a array of pointers to characters returns an integer quantity
 (d)None of these
 
 [Q014] Several declarations involving pointers are shown below. Pick the correct solution.
int *(*ptr)(char (*a)[]);
 (a)ptr is a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (b)ptr is a pointer to a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (c)ptr is a pointer to a function that accepts an argument which is a array of pointers to characters returns a pointer to an integer quantity
 (d)None of these 
 
[Q015] Several declarations involving pointers are shown below. Pick the correct solution.
int *(*ptr)(char (*a)[]);
   (a)ptr is a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (b)ptr is a pointer to a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (c)ptr is a pointer to a function that accepts an argument which is an array of pointers to characters returns a pointer to an integer quantity
 (d)None of these
 
[Q016] Several declarations involving pointers are shown below. Pick the correct solution.
int (*ptr[10])(void); 
 (a)Invalid statement
 (b)ptr is a function that returns an integer quantity
 (c)ptr is a 10-element array of pointers to functions. Each function returns an integer quantity.
 (d)ptr is pointer to a function that returns a pointer to a 10-element integers
 
 
[Q017] Several declarations involving pointers are shown below. Pick the correct solution.
int (*ptr[10])(float a);
 
(a)Invalid statement
 (b)ptr is a function that returns an integer quantity
 (c)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a float and returns an integer quantity.
 (d)ptr is pointer to a function that accepts an argument which is a float and returns a pointer to a 10-element integers
  
 
 [Q018] Several declarations involving pointers are shown below. Pick the correct solution.
 int *(*ptr[10])(float a);  
(a)Invalid statement
 (b)ptr is a function that returns an integer quantity
 (c)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a float and returns an integer quantity.
 (d)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a float and returns a pointer to an integer quantity. 
 
[Q019] Several declarations involving pointers are shown below. Pick the correct solution.
 int *(*ptr[10])(float *a); 
(a)Invalid statement
 (b)ptr is a function that returns an integer quantity
 (c)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a pointer to a float and returns an integer quantity.
 (d)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a pointer to a float and returns a pointer to an integer quantity.
  
 
 [Q020] Several declarations involving pointers are shown below. Pick the correct solution.
 int *ptr(char (*a)[]);
(a)ptr is a function pointer
 (b)ptr is a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 (c)ptr is a function that accepts an argument which is a array of pointers to characters returns a pointer to an integer quantity
 (d)None of these
 

 
SOLUTIONS

Solutions : Pointers - Part I
[Q001] 
 (b)ptr is a pointer to an integer quantity
 
 [Q002] 
 (c)ptr is a 10-element array of pointers to integer quantities
 
[Q003] 
 (b)ptr is a pointer to a 10-element integer array
 
[Q004]
 (b)ptr is a function that returns a pointer to an integer quantity
 
[Q005] 
(b)ptr is a function that accepts an argument which is a pointer to a integer returns an integer quantity
 
[Q006] 
 (c)ptr is a function that accepts an argument which is a pointer to a integer returns a pointer to an integer quantity
 
[Q007] 
 (b)ptr is a pointer to a function that accepts an argument which is a pointer to a character returns an integer quantity
 
[Q008] 
  (c)ptr is a function that accepts an argument which is a pointer to a integer returns a pointer to a 5-element integer array
 
[Q009] 
 (b)ptr is a function that accepts an argument which is a pointer to a integer array returns an character quantity
 
[Q010] 
(c)ptr is a function that accepts an argument which is an array of  pointers to integers returns an character quantity
 
[Q011]
 (c)ptr is a function that accepts an argument which is a character array returns a pointer to an integer quantity
 
[Q012] 
(c)ptr is a function that accepts an argument which is a array of pointers to characters returns a pointer to an integer quantity
 
[Q013] 
   (b)ptr is a pointer to a function that accepts an argument which is a pointer to a character array returns an integer quantity
 
[Q014]
  
(b)ptr is a pointer to a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity
 
[Q015] 
  (c)ptr is a pointer to a function that accepts an argument which is an array of pointers to characters returns a pointer to an integer quantity
 
[Q016] 
 (c)ptr is a 10-element array of pointers to functions. Each function returns an integer quantity
 
 [Q017] 
 (c)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a float and returns an integer quantity
 
[Q018] 
 (d)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a float and returns a pointer to an integer quantity
 
 [Q019] 
(d)ptr is a 10-element array of pointers to functions. Each function accepts an argument which is a pointer to a float and returns a pointer to an integer quantity
 
[Q020]
 (b)ptr is a function that accepts an argument which is a pointer to a character array returns a pointer to an integer quantity

 

 
 

 

 

Thank You.. Visit Again

This website was created for free with Own-Free-Website.com. Would you also like to have your own website?
Sign up for free