All India Exams
Home AptitudeBankEngineeringEnglishGKInterviewOnline TestPlacement PapersReasoning
  • Home
  • Aptitude
  • Bank
  • Engineering
  • English
  • GK
  • Interview
  • Online Test
  • Placement Papers
  • Reasoning

Pointers C++ Questions And Answers

Here you can find Pointers C++ Questions and Answers.

Why Pointers C++ Questions and Answers Required?

In this Pointers C++ Questions and Answers section you can learn and practice Pointers C++ Questions and Answers to improve your skills in order to face technical inerview conducted by Banks. By Practicing these interview questions, you can easily crack any Bank Exams interview.

Where can I get Pointers C++ Questions and Answers?

AllIndiaExams provides you lots Pointers C++ Questions and Answers with proper explanation. Fully solved examples with detailed answer description. All students, freshers can download Pointers C++ Questions and Answers as PDF files and eBooks.

How to solve these Pointers C++ Questions and Answers?

You no need to worry, we have given lots of Pointers C++ Questions and Answers and also we have provided lots of FAQ's to quickly answer the questions in the Bank Exams interview.

Pointers C++ Questions & Answers

1. What does the following statement mean? int (*fp)(char*)

Pointers C++ Questions & Answers

2. The operator used for dereferencing or indirection is ____

Pointers C++ Questions & Answers

3. Choose the right option string* x, y;

Pointers C++ Questions & Answers

4. Which one of the following is not a possible state for a pointer?

Pointers C++ Questions & Answers

5. Which of the following is illegal?

Pointers C++ Questions & Answers

6. What will happen in this code? int a = 100, b = 200; int *p = &a, *q = &b; p = q;

Pointers C++ Questions & Answers

7. What is the output of this program? #include < iostream > using namespace std; int main() { int a = 5, b = 10, c = 15; int *arr[ ] = {&a, &b, &c}; cout << arr[1]; return 0; }

Pointers C++ Questions & Answers

8. The correct statement for a function that takes pointer to a float, a pointer to a pointer to a char and returns a pointer to a pointer to a integer is

Pointers C++ Questions & Answers

9. What is the output of this program? #include < iostream > using namespace std; int main() { char arr[20]; int i; for(i = 0; i < 10; i++) *(arr + i) = 65 + i; *(arr + i) = '\0'; cout << arr; return(0); }

Pointers C++ Questions & Answers

10. What is the output of this program? #include < iostream > using namespace std; int main() { char *ptr; char Str[] = "abcdefg"; ptr = Str; ptr += 5; cout << ptr; return 0; }

Home EngineeringComputer Science & EngineeringC++ Multiple Choice Questions & AnswersPointers

Pointers - C++ Questions and Answers

This is the c++ programming questions and answers section on "Pointers" with explanation for various interview, competitive examination and entrance test. Solved examples with detailed answer description, explanation are given and it would be easy to understand.

Pointers C++ Questions

Online Test Name Pointers
Exam Type Multiple Choice Questions
Category Computer Science Engineering Quiz
Number of Questions 17
1.

 What does the following statement mean?

     int (*fp)(char*)

  • A. pointer to a pointer
  • B. pointer to an array of chars
  • C. pointer to function taking a char* argument and returns an int
  • D. function taking a char* argument and returning a pointer to int
  • View Answer
  • Workspace
  • Report
  • Discuss

Answer & Explanation

Answer: Option C

Explanation:

pointer to function taking a char* argument and returns an int

Workspace

Report Error


2. The operator used for dereferencing or indirection is ____
  • A. *
  • B. &
  • C. ->
  • D. ->>
  • View Answer
  • Workspace
  • Report
  • Discuss

Answer & Explanation

Answer: Option A

Explanation:

*

Workspace

Report Error


3.

Choose the right option

     string* x, y;

  • A. x is a pointer to a string, y is a string
  • B. y is a pointer to a string, x is a string
  • C. both x and y are pointer to string types
  • D. none of the mentioned
  • View Answer
  • Workspace
  • Report
  • Discuss

Answer & Explanation

Answer: Option A

Explanation:

* is to be grouped with the variables not the data types.

Workspace

Report Error


4. Which one of the following is not a possible state for a pointer?
  • A. hold the address of the specific object
  • B. point one past the end of an object
  • C. zero
  • D. point to a tye
  • View Answer
  • Workspace
  • Report
  • Discuss

Answer & Explanation

Answer: Option D

Explanation:

A pointer can be in only 3 states a,b and c.

Workspace

Report Error


5. Which of the following is illegal?
  • A. int *ip;
  • B. string s, *sp = 0;
  • C. int i; double* dp = &i;
  • D. int *pi = 0;
  • View Answer
  • Workspace
  • Report
  • Discuss

Answer & Explanation

Answer: Option C

Explanation:

dp is initialized int value of i.

Workspace

Report Error


  • «
  • 1
  • 2
  • 3
  • 4
  • »

Related Topics:

  • Inheritance
  • Namespaces
  • Constants
  • Classes
  • Templates
  • Macros
  • Functions
  • Interfaces
  • Operators and Statements
  • Input Output Streams

Mock Tests & Online Quizzes

  • Aptitude Online Test

  • Reasoning Online Test

  • GK Online Test

  • English Online Test

  • RRB Mock Test

  • RBI Mock Test

  • Free SBI Mock Test

  • IBPS Mock Test FREE

  • SSC Mock Test

  • CAT Exam Mock Test

  • GATE Mock Test

  • IT Courses Quiz

Questions and Answers

  • Aptitude Questions
  • Verbal Reasoning Questions
  • Non Verbal Reasoning
  • Logical Reasoning Questions
  • Data Sufficiency Questions
  • Data Interpretation
  • eLitmus Sample Papers
  • ECE Questions and Answers
  • EEE Questions and Answers
  • Verbal Ability Questions
  • GK Questions

Programming Quiz

  • C Programming
  • C++ Programming
  • PHP Programming
  • Java Programming
  • Python Programming
  • DataScience MCQ
  • Hadoop MCQ
  • Mongo DB MCQ
  • MySQL MCQ

Interview Questions

  • Java Interview Questions
  • .Net Interview Questions
  • Networking Interview Questions
  • C Language Interview Questions
  • C++ Interview Questions
  • Testing Interview Questions
  • Android Interview Questions
  • HR Interview Questions
  • Group Discussion Topics

Our Sites

AView.in

© by AllIndiaExams.in. All Rights Reserved | Copyright | Terms of Use & Privacy Policy