Communiquez avec les autres et partagez vos connaissances professionnelles

Inscrivez-vous ou connectez-vous pour rejoindre votre communauté professionnelle.

Suivre

How is c different from c++?

user-image
Question ajoutée par Amreen Fatima , MANAGEMENT TRAINEE AS A SOFTWARE DEVELOPER , I-NEXT SOLUTION
Date de publication: 2015/10/20
IMRAN ALI MOHAMMED
par IMRAN ALI MOHAMMED , Accounts Officer , M/s. Euro Glazing Ltd

While C is the widely used programming language, its efficiency lies in its converting in to machine instructions. Below are some of the features which differs C from C++

 

1. C is a middle level language, C++ is a high level language

2. C does not supports vitual functions, whereas C++ offers the facility

3. C uses top-down approach, C++ uses botton-up approach

4. C- inheritance not possible, in C++ its possible

5. C- All variables must be declared at the beginning of scope, whereas in C++ it is possible to declare variables anywhere within the scope

6. C- Mapping between data and function is difficult, in C++ they can be mapped easily using objects

7. C supports only built in data, C++ supports both built in aswell as user define types

8. C - programmes are saved in files with extension .c, in C++ with extension .cpp

Gayasuddin Mohammed
par Gayasuddin Mohammed , Advocate , Practicing Law before High Court at Hyderabad

Agreed with the answer of our friend Mr. Abid Saleem.

In addition to that, simply C++ is plus plus(additional/next level language with OOP concepts) in terms of object oriented approach to the procedural programming language C.

In simple terms, If you are good in C and OOP concepts, you can be good in C++ as it is a combination of C language and OOP concepts only.

Thanks.

 

Abid Saleem
par Abid Saleem , Assistant Resident Engineer , Umar Munshi Associates

Functions are the building blocks of a C program while objects are building blocks of a C++ program.

Syed Muhammad Ali Rizvi
par Syed Muhammad Ali Rizvi , Oracle Hrms Functional Consultant , Inbox Consulting Pakistan

C is primary language that used for computer programming while C is the structure language while on the other hand C++  is Object Oriented Paradigm although C++ is derived from C as mother language

danish Akbar
par danish Akbar , Software Engineer , northstar

c++ supports oop as c does not