Tuesday, February 3, 2009

structured VS Object oriented programmming

There are advantages as well as disadvantages to using either structured programming languages or object-oriented languages when developing an application.
c is a structured while c++ is Object oriented language.
There is an advantage to using structured programming when writing classes and complex functions are not necessary. It can take up more time and energy to develop classes rather than simply write a straightforward piece of code, which executes a specific set of commands. It depends on what the overall purpose of the program is. One of the main disadvantages to using a structured programming language versus an object-oriented language is that it is not ‘modular’. In other words, the code is not split up into reusable sections. The code is written and executed sequentially; therefore you may have redundant code. It may take longer to develop programs using structured language

One of the advantages to using object-oriented programming languages is that it is modular. It is possible to write a reusable piece of code, such as a function or a class, which can be used multiple times throughout a program without having to rewrite it. This can save the developer much time and effort in the development process. One of the possible disadvantages to using an object-oriented programming language is its sheer complexity. It is not typically recommended to use object-oriented languages when developing smaller, less complex programs or programs that are built to run on low powered computers

No comments:

Post a Comment