CHAPTER 2

image

Pointer Basics

Like any other variable, you need to first understand the basics of pointer variables. The basics include declaration, definition, and usage. This chapter explains the concept of pointer variables. The emphasis is on the usage of pointers with the help of diagrams to visualize the concepts. This chapter also explains the inner details of memory allocation and deallocation, and how pointer variables manipulate them.

Pointers by definition are variables used to store memory addresses of data or functions, unlike other data type variables that are used to store only the value. As with any usual variable, a pointer takes ...

Get Pointers in C: A Hands on Approach now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.