C is the base to all kind of Programming Languages. Simply the enhancement of C language is C++. C++ is a general-purpose object-oriented programming (OOPS) language and Java is a general purpose, high-level programming language. Here I Provide a complete difference between C, C++ and JAVA in a simplified manner.
1. Bharathiar University
Re - Accredited by NAAC with “A” Grade - Awarded 14 Rank by MHRD - NIRF,
Govt. of India.
Difference between C, C++ and JAVA
N.MOHANASUNDARAM
II - MCA
(Reg. No. 15CSEA52)
DEPARTMENT OF COMPUTER APPLICATIONS
SCHOOL OF COMPUTER SCIENCE AND ENGINEERING
BHARATHIAR UNIVERSITY
COIMBATORE - 641046
TAMILNADU
2. What is the C language?
C is a high-level and general purpose programming language that is ideal
for developing firmware or portable applications. Originally intended for writing
system software, C was developed at Bell Labs by Dennis Ritchie for the Unix
Operating System (OS) in the early 1970s.
What is the C++ language?
C++ is a general-purpose object-oriented programming (OOP) language,
developed by Bjarne Stroustrup, and is an extension of the C language. It is
therefore possible to code C++ in a "C style" or "object-oriented style."
C++ is considered to be an intermediate-level language, as it encapsulates
both high- and low-level language features. Initially, the language was called "C
with classes" as it had all the properties of the C language with an additional
concept of "classes." However, it was renamed C++ in 1983.
What is the Java language?
Java is a general purpose, high-level programming language developed by
Sun Microsystems. The Java programming language was developed by a small
team of engineers, known as the Green Team, who initiated the language in 1991.
The language was originally called OAK, and at the time it was designed for
handheld devices and set-top boxes. Oak was unsuccessful and in 1995 Sun
changed the name to Java and modified the language to take advantage of the
burgeoning World Wide Web.
Later, in 2009, Oracle Corporation acquired Sun Microsystems and took
ownership of two key Sun software assets: Java and Solaris.
3. Difference between C, C++ and Java:
Aspects C C++ Java
Developed Year 1972 1979 1991
Developed By Dennis Ritchie Bjarne Stroustrup James Gosling
Successor of BCPL C
C(Syntax) & C++
(Structure)
Paradigms Procedural Object Oriented Object Oriented
Platform Dependency Dependent Dependent Independent
Keywords 32 63
50 defined (goto, const
unusable)
Datatypes : union,
structure
Supported Supported Not Supported
Pre-processor
directives
Supported (#include,
#define)
Supported
(#include, #define)
Not Supported
Header files Supported Supported Use Packages (import)
Inheritance No Inheritance Supported
Multiple Inheritance not
Supported
Overloading No Overloading Supported
Operator Overloading
not Supported
Pointers Supported Supported No Pointers
Code Translation Compiled Compiled Interpreted
Storage Allocation Uses malloc, calloc Uses new , delete uses garbage collector
Multi-threading and
Interfaces
Not Supported Not Supported Supported
Exception Handling
No Exception
handling
Supported Supported
Templates Not Supported Supported Not Supported
Storage class: auto,
extern
Supported Supported Not Supported
Destructors
No Constructor or
Destructor
Supported Not Supported
Database Connectivity Not Supported Not Supported Supported