C C++
C C++
Himani Kathal
What is C?
C is a high-level structured oriented programming
language, used in general-purpose programming .
C works with an in-built complier, as it works on
converting C from being a programming language into
a machine readable coded language.
C is the most preferred language for decades now, due
to its high performance, remarkable efficiency and its
portability.
C is a successor of 'Basic Combined Programming
Language' (BCPL) called B language.
What are the advantages of C?
Portable: Its portability allows code to run on different
computers and different operating systems without making any
change.
Efficient: It is a general-purpose programming language.
Therefore it works efficiently.
Case-sensitive: You need to be very careful while writing the
code as it treats lowercase and uppercase letter differently.
Memory Manipulation and allocation: It has the ability to
manipulate arbitrary memory addresses. It also allows
allocating the memory dynamically.
Middle-level language: It merges the features of
both low level and high-level languages in itself.
What are the disadvantages of C?
C language is devoid with the terminology and
the concept of OOPS which is a very popular and an
important concept these days among all high-level
programming language.
No Strict type checking possible.
No checks for runtime
It doesn’t give us the provision of having a namespace.
It also doesn’t have the concept of the constructor as
well as a destructor.
Why should we use C language?
It makes the code size small.
It is efficient, portable, structured and well
understood.
It has only 32 keywords which are easy to remember.
It is near to Assembly language as code written in C
language runs as fast as code written in assembly
language.
It has Pointers which connects hardware like as
kernel, drivers to a system, because of this
reason C will always be in use.
What are the characteristics of C?
Low-level memory access: The lightweight programming
language requires a low level of memory access and hence
is a good fit for system programming.
Simplified keyword set: Rich and easy to understand and
use a set of simplified keywords that meet
one of the most important characteristics of this language
The clean style: This language focuses on keeping the
code neat and tidy and hence the code flow is clean.
Pointer mechanism: The efficient use of pointer and
addressing mechanism in C language makes it a unique
and a different characteristic from all other programming
languages.
It is a very robust language with a rich set of built-in
operators and functions.
The programs which are coded in C are fast and more
efficient
It is a highly portable language. It means that once the
programs which are written in C can easily run on
various other machines with next to no modification.
It has a very huge collection of the library or built-in
functions. It also provides us the capabilities to custom
or create our own function and include it in the
collection of C library.
It is a highly extensible language.
What are applications of c?
What are the basic commands of c?
#include: This is the main header file preprocessor
command which includes standard input and output
header file such as stdio.h from the C library repository
before the program is compiled.