Chapter 19. Object-Oriented Programming

BECAUSE OBJECT-ORIENTED PROGRAMMING (OR OOP) is so popular, and because many of the widely used OOP languages—such as C++, C#, Java, and Objective-C—are based on the C language, a brief introduction to this topic is presented here. The chapter starts with an overview about the concepts of OOP, and then shows you a simple program in three of the four aforementioned OOP languages (I picked the three that contain the word “C”!). The idea here is not to teach you how to program in these languages or even to describe their main features so much as it is to give you a quick taste.

What Is an Object Anyway?

An object is a thing. Think about object-oriented programming as a thing and something you want to do to that ...

Get Programming in C, Third Edition 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.