Skip to main content

History of C language

.

History of C Language


History of C language is interesting to know. Here we are going to discuss brief history of c language.

C is an imperative procedural language.C is a general-purpose language which has been closely associated with the UNIX operating system for which it was developed - since the system and most of the programs that run it are written in C.
C programming language was developed in 1972 by Dennis Ritchie at bell laboratories of AT&T (American Telephone & Telegraph), located in U.S.A.

C was developed at Bell Laboratories as a system programming language to implement a new operating system on a DEP PDP-11 minicomputer. The project began in 1972, and a language description was published six years later (Kernighan and Ritchie, 1978) [C is a compact terse programming language that includes data types, data separations, the ability to manipulate addresses, and uncomplicated but complete set of flow control constructions.
Dennis Ritchie is known as the founder of c language.

Many of its principles and ideas were taken from the earlier language B and B's earlier ancestors BCPL and CPL. CPL ( Combined Programming Language ) was developed with the purpose of creating a language that was capable of both high level, machine independent programming and would still allow the programmer to control the behavior of individual bits of information


How to Variables Declare


Variable Declaration



Usually Variables are declared before use either at the start of a block of code after the opening {and before any other statements or outside a function.

-------------------------------------------------------------------------------------------------------------------------------------------------
int a,b;/*global variables*/
main()
{
float a;/*local variables
}
--------------------------------------------------------------------------------------------------------------------------------------------------
Local variables can only accessed within that function only whereas Global variables can access in whole program.

Variable Types

There are many 'built-in' data types in C.

short int -128 to 127 (1 Byte)
unsigned short int 0 to 255 (1 Byte)
char 0 to 255 or -128 to 127 (1 Byte)
v Unsigned char 0 to 255 (1 Byte)
signed char-128 to 127 (1 Byte)
int -32,768 to +32,767 (2 Byte)
unsigned int 0 to +65,535 (2 Bytes)
long int -2,147,483,648 to +2,147,483,647 (4 bytes)
unsigned long int 0 to 4,294,967,295 (4 Byte)
double double precision floating point (8 Byte)
long double extended precision floating point(10 Bytes)

Variable Names

we can use any combination of letters and numbers for Variables and function names but it must start with a letter.
We can use Underscore (_) as a letter in variable name and can begin with an underscore But Identifiers beginning with an underscore are reserved, And identifiers beginning with an underscore followed by a lower case letter are reserved, for file scope identifiers Therefore using Underscore as starting letter is not desirable.


Piku and piku are different identifiers because upper and lower case letters are treated as different identifiers.

Comments

Popular posts from this blog

Blogger Welcome to Education Blog Education is the act of learning things around us. It helps us to easily understand and deal with any problem and makes balance throughout the whole life in every aspect. Education is the first and foremost rights of every human being. Without education we are incomplete and our lives are useless. Education helps us to set a goal and go ahead by working on that throughout the life. It improves our knowledge, skill, confidence level and personality. It empowers us intellectually to interact with others in our life. Education brings maturity and teaches us to live in society with changing environment. It is the way to social development, economic growth and technological development.Education plays a great role in everyone’s life by building personality, improving knowledge and skill and providing feeling of well being of a person. Education has been divided into three categories in our country as Primary education, Secondary education and Highe...

Use of statement in python

Use of statement of Python: Use of if – else statement:-if – else is the variation of if statement. We attach condition with if statement if given condition is true then if block code will executed and if the given condition is false then else block code will executed. The syntax of if – else statement is given below:- if condition: Statement 1 Statement 2 else: Statement 3 Statement 4 Write a program in python to check the given number is even or odd. n=input(“Enter a number : ”) if n%2==0: print “The number ”,n,”is even” else: print “The number”,n,”is odd” Use of if-else ladder:- In Python language the switch statement is not worked. In Python we use if-else ladder in spite of using switch. The syntax of if-else ladder is given below:- if condition1: Statement 1 elif condition 2: Statement 2 elif condition 3: Statement 3 >br> else: Statement 4 Write a program in python to find greatest number in three numbers. a=input(“Enter firs...
Inspirational Quotes on Education School may have been – or may currently be – boring, a killer of creativity or downright awful for you. But education is still important because it opens the mind and expands it. And if your years in school were bad or boring you can still educate yourself now. So in this post I’d like to share 54 timeless, thought-provoking and inspiring quotes on education. “It is impossible for a man to learn what he thinks he already knows.”                         Mark Zuckerberg. In this success story, we are going to share Mark Zuckerberg biography, the youngest billionaire on the planet who created the Facebook social network that now has 1 billion monthly active users. Thanks to Facebook people around the world can easily keep in touch with all their friends. Not long ago, society just did not have such opportunity, but now...