Solved

Difference b/w c and c++

Posted on 2003-12-09
2
1,646 Views
Last Modified: 2008-02-26
What are the main differences b/w c and c++
0
Comment
Question by:hellhe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Accepted Solution

by:
minamkhan earned 125 total points
ID: 9907738
Actually c is a structured language whereas c++ is  hybrid language in which one can write both structured and objectoriented code.
0
 
LVL 11

Expert Comment

by:bcladd
ID: 9907751
C++ is object-oriented and C is not.

C++ supports inheritance through the use of related (inherited) classes.
C++ supports polymorphism through the use of virtual funcitons.

C++ supports meta-programming using templates; C and C++ share a preprocessor and many things are possible using macro definitions but templated classes and functions permit more complex, compile-time progrmaming (known as meta programming in the C++ literature).

C++ has exception handling

C++ has the Standard Template Library (STL), a standard library that has a string class as well as dynamically sized container classes that are efficient and easy to use.

C++ is, generally speaking, a super-set of C (I know Plauger would beat me for that generalization).

Hope this helps, -bcl
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question