Skip to main content
PreparationZone Logo
PreparationZone
Back to Fundamentals

Fundamentals · Medium · Free

For C/C++ interviews: pointer vs reference vs address-of operator.

FresherFundamentalsOOP & Language Fundamentals
Model answer

Pointer vs reference (C++)

PointerReference
Syntaxint* pint& r
NullCan be nullptrMust bind to object
RebindCan point elsewhereCannot reseat

& address-of gives pointer; * dereferences. References are aliases—often for parameters to avoid copy.

Java has references without pointer arithmetic—mention if interview is C++ specific.