From: Greg Moorer Newsgroups: comp.os.msdos.djgpp Subject: Re: What is object orientated programming Date: Thu, 20 Nov 1997 18:03:37 -0600 Organization: Mississippi State University Lines: 26 Message-ID: <3474CFD9.487E@ra.msstate.edu> References: <880060136 DOT 22763 DOT 0 DOT nnrp-03 DOT c2de5740 AT news DOT demon DOT co DOT uk> NNTP-Posting-Host: port10-ts01.dialup.msstate.edu Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk > What is object orientated programming and in what way does it differ > from normal C. > Object Oriented Programming is a good thing... after first learning OOP in C++ and then having to go back to C for some Corps of Engineers work, I am very much in favor of OOP. At first glance OOP looks merely like creating structures that have member functions in addition to the normal data members. However, it is really a lot more. One thing that's great is inheritance [sp?]... you can create one class that encapsulates one form of object. Then you come in and create other classes that inherit the traits of that base class and add more specific functions and data to describe a more precise version of that object. For instance you can create a door object for a D&D style game, later you can come in and create new objects that inherit the original door characteristics (Isitopen, Isitstuck, etc.) such as a lockable door which has a new flag in it's member data (Isitlocked). Another good thing is polymorphism... this basicly involves controlling which function will be called if an inherited class has an identicle function name, but does something different than the class it is inherited from. Hope that helps, -Greg