What is the difference among a pointer and a reference?, C/C++ Programming

A: A reference has to always refer to some object and, so, must always be initialized; pointers do not have such limits. A pointer may be reassigned to point to distinct objects whereas a reference always refers to an object along with which it was initialized.

 

Posted Date: 3/19/2013 9:02:16 AM | Location : United States







Related Discussions:- What is the difference among a pointer and a reference?, Assignment Help, Ask Question on What is the difference among a pointer and a reference?, Get Answer, Expert's Help, What is the difference among a pointer and a reference? Discussions

Write discussion on What is the difference among a pointer and a reference?
Your posts are moderated
Related Questions
What are compound statements? - Compound statements are made up of two or more program statements that are executed together. They may be executed with a loop. - Curly brack


c-program to find the area under the curve y=f(x) between x=a and x=b integrate y=f(x) between the limits of a and b   #include float start_point, /


A: Depends. Might be "zero" Objects which are thrown must have a publicly accessible copy-constructor. The compiler is permitted to generate code which copies the thrown object

Write a C++ program which does the following: 1. Asks the user to enter the following text "Four score and seven years ago there was a man named Joey Bagadonuts." 2. Save thi

A string S is said to be "Super ASCII", if it contains the character frequency equal to their ascii values. String will contain only lower case alphabets (''''a''''-''''z'''') and

Define Scope Rules of C program - Computer Programming? The fundamental rule of scope is that identifiers are accessible only within the block in which they are declared and th

Add words in Dictionary: void Dictionary::add( Object& objectToAdd ) {     if( !objectToAdd.isAssociation() )         ClassLib_error( __ENOTASSOC );     else

Create an applet that bounces a blue ball inside an applet using Thread. The ball (diameter is 10) will start at position (0,0). When the ball hits the edge of the applet, the ba