O'Reilly logo

Functional Programming: A PragPub Anthology by Michael Swaine

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Object-Oriented Model

To understand why, let’s take a look at simplified computer memory. It consists of a series of eight memory cells, each of which holds a bit of information. Every cell has an address, which represents a place. You can reach into that place and change what’s there, but once you change it, any notion of what was there in the past is lost as shown in the figure.

images/MBL-images/SuperSimpleMemory.png

To change a value, the bit at a particular location is flipped. For instance, in the following dramatic re-enactment, we change the value at memory location 8 from 0 to 1.

This simplified model is similar to the model presented by even modern computer memory. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required