Re: Is C a block structured language?
OK. Here goes.
C is a blocked structured language.
C++ is to replace C.
Therefore, C++ is also a blocked structured language.
Now C++ does have some OO features (which you don't have to use) but even if you do, the program is still block structured. It's just that you don't need to code all of the block calls yourself like you would have to do in C.
An object-oreinted language ahs to support the Liskow Substitution Principle. This principle says a derived object can be substituted for a base object and thereafter when treated as a base object behaves like the derived object that it really is.
You cannot do this in C++. The most you can do is substitute the address of a derived objec as the address of a base object but you cannot substitute the object itself. In this sense C++ is not object-oriented.
However, the address substitution is usually enough to accomplish the same end as substituting th actual object so in that sense you can say that C++ can be object-oriented.
Please note that that a C++ program has calls made by the compiler to accomplish the object-oriented magic. Were you to have a C program, you could make those calls yourself and have an object-oriented program in C.
Note that block structured does not always mean defining procedures within procedures but also means using procedures wirthin procedures. Neither C nor C++ permits defining a procedure within a procedure but you can certainly use procedures within procedures.