ANSI C Pointers 101

Standard

Hi, I believe that Pizza and The C Programming Language are two of the most awesome things in the Universe. Also, I have a thesis:  The Universe was created by Morgan Freeman using just ANSI C code and Pizza, think about it! (I’m quite sure that Neil deGrasse Tyson has already done it). Celebrating this spiritual belief I’ll explain some very essential rules that govern our reality (#SpoilerAlert: I’ll talk about Pointers in C) in a basic but really different way.

The key concepts served in this post are:

  1. The use of pointers to manipulate variables.
  2. The use of pointers to access the elements of an array.
  3. The use of pointers to cast data across different data types.

As you might already imagine I’ll dish up these ideas with the magic of a crispy crust, tomato sauce and a lot of cheese (#OhYeah). But before we begin, I’ll expect from you a basic knowledge about C (mainly data types, variables and functions). O.K. lets go!

Continue reading